dev
dart 436 lines 12.3 KB
Raw
1 final trc20Abi = [
2 {"inputs": [], "stateMutability": "nonpayable", "type": "constructor"},
3 {
4 "anonymous": false,
5 "inputs": [
6 {"indexed": true, "internalType": "address", "name": "owner", "type": "address"},
7 {"indexed": true, "internalType": "address", "name": "spender", "type": "address"},
8 {"indexed": false, "internalType": "uint256", "name": "value", "type": "uint256"}
9 ],
10 "name": "Approval",
11 "type": "event"
12 },
13 {
14 "anonymous": false,
15 "inputs": [
16 {"indexed": false, "internalType": "uint256", "name": "total", "type": "uint256"},
17 {"indexed": true, "internalType": "uint16", "name": "order_id", "type": "uint16"},
18 {"indexed": true, "internalType": "address", "name": "buyer", "type": "address"},
19 {"indexed": true, "internalType": "address", "name": "seller", "type": "address"},
20 {"indexed": false, "internalType": "address", "name": "contract_address", "type": "address"}
21 ],
22 "name": "OrderPaid",
23 "type": "event"
24 },
25 {
26 "anonymous": false,
27 "inputs": [
28 {"indexed": true, "internalType": "address", "name": "previousOwner", "type": "address"},
29 {"indexed": true, "internalType": "address", "name": "newOwner", "type": "address"}
30 ],
31 "name": "OwnershipTransferred",
32 "type": "event"
33 },
34 {
35 "anonymous": false,
36 "inputs": [
37 {"indexed": false, "internalType": "address", "name": "token", "type": "address"},
38 {"indexed": false, "internalType": "bool", "name": "active", "type": "bool"}
39 ],
40 "name": "TokenUpdate",
41 "type": "event"
42 },
43 {
44 "anonymous": false,
45 "inputs": [
46 {"indexed": true, "internalType": "address", "name": "from", "type": "address"},
47 {"indexed": true, "internalType": "address", "name": "to", "type": "address"},
48 {"indexed": false, "internalType": "uint256", "name": "value", "type": "uint256"}
49 ],
50 "name": "Transfer",
51 "type": "event"
52 },
53 {
54 "anonymous": false,
55 "inputs": [
56 {"indexed": false, "internalType": "string", "name": "username", "type": "string"},
57 {"indexed": true, "internalType": "address", "name": "seller", "type": "address"}
58 ],
59 "name": "UserRegistred",
60 "type": "event"
61 },
62 {
63 "anonymous": false,
64 "inputs": [
65 {"indexed": true, "internalType": "uint16", "name": "order_id", "type": "uint16"},
66 {"indexed": true, "internalType": "address", "name": "buyer", "type": "address"},
67 {"indexed": false, "internalType": "address", "name": "seller", "type": "address"}
68 ],
69 "name": "WBuyer",
70 "type": "event"
71 },
72 {
73 "anonymous": false,
74 "inputs": [
75 {"indexed": true, "internalType": "uint16", "name": "order_id", "type": "uint16"},
76 {"indexed": true, "internalType": "address", "name": "seller", "type": "address"},
77 {"indexed": false, "internalType": "address", "name": "buyer", "type": "address"}
78 ],
79 "name": "WSeller",
80 "type": "event"
81 },
82 {
83 "inputs": [],
84 "name": "CONTRACTPERCENTAGE",
85 "outputs": [
86 {"internalType": "uint8", "name": "", "type": "uint8"}
87 ],
88 "stateMutability": "view",
89 "type": "function"
90 },
91 {
92 "inputs": [
93 {"internalType": "uint16", "name": "order_id", "type": "uint16"},
94 {"internalType": "uint256", "name": "order_total", "type": "uint256"},
95 {"internalType": "address", "name": "contractAddress", "type": "address"},
96 {"internalType": "address", "name": "seller", "type": "address"}
97 ],
98 "name": "PayWithTokens",
99 "outputs": [],
100 "stateMutability": "nonpayable",
101 "type": "function"
102 },
103 {
104 "inputs": [],
105 "name": "TOKENINCREAMENT",
106 "outputs": [
107 {"internalType": "uint16", "name": "", "type": "uint16"}
108 ],
109 "stateMutability": "view",
110 "type": "function"
111 },
112 {
113 "inputs": [
114 {"internalType": "address", "name": "", "type": "address"}
115 ],
116 "name": "_signer",
117 "outputs": [
118 {"internalType": "bool", "name": "", "type": "bool"}
119 ],
120 "stateMutability": "view",
121 "type": "function"
122 },
123 {
124 "inputs": [
125 {"internalType": "address", "name": "", "type": "address"}
126 ],
127 "name": "_tokens",
128 "outputs": [
129 {"internalType": "bool", "name": "active", "type": "bool"},
130 {"internalType": "uint16", "name": "token", "type": "uint16"}
131 ],
132 "stateMutability": "view",
133 "type": "function"
134 },
135 {
136 "inputs": [
137 {"internalType": "address", "name": "", "type": "address"}
138 ],
139 "name": "_users",
140 "outputs": [
141 {"internalType": "bool", "name": "active", "type": "bool"}
142 ],
143 "stateMutability": "view",
144 "type": "function"
145 },
146 {
147 "inputs": [
148 {"internalType": "address", "name": "owner", "type": "address"},
149 {"internalType": "address", "name": "spender", "type": "address"}
150 ],
151 "name": "allowance",
152 "outputs": [
153 {"internalType": "uint256", "name": "", "type": "uint256"}
154 ],
155 "stateMutability": "view",
156 "type": "function"
157 },
158 {
159 "inputs": [
160 {"internalType": "address", "name": "spender", "type": "address"},
161 {"internalType": "uint256", "name": "amount", "type": "uint256"}
162 ],
163 "name": "approve",
164 "outputs": [
165 {"internalType": "bool", "name": "", "type": "bool"}
166 ],
167 "stateMutability": "nonpayable",
168 "type": "function"
169 },
170 {
171 "inputs": [
172 {"internalType": "address", "name": "account", "type": "address"}
173 ],
174 "name": "balanceOf",
175 "outputs": [
176 {"internalType": "uint256", "name": "", "type": "uint256"}
177 ],
178 "stateMutability": "view",
179 "type": "function"
180 },
181 {
182 "inputs": [
183 {"internalType": "address", "name": "token", "type": "address"}
184 ],
185 "name": "balanceOfContract",
186 "outputs": [
187 {"internalType": "uint256", "name": "", "type": "uint256"}
188 ],
189 "stateMutability": "view",
190 "type": "function"
191 },
192 {
193 "inputs": [
194 {"internalType": "uint256", "name": "amount", "type": "uint256"}
195 ],
196 "name": "burn",
197 "outputs": [],
198 "stateMutability": "nonpayable",
199 "type": "function"
200 },
201 {
202 "inputs": [
203 {"internalType": "address", "name": "account", "type": "address"},
204 {"internalType": "uint256", "name": "amount", "type": "uint256"}
205 ],
206 "name": "burnFrom",
207 "outputs": [],
208 "stateMutability": "nonpayable",
209 "type": "function"
210 },
211 {
212 "inputs": [
213 {"internalType": "uint256", "name": "value", "type": "uint256"},
214 {"internalType": "address", "name": "_contractAddress", "type": "address"}
215 ],
216 "name": "contractWithdraw",
217 "outputs": [],
218 "stateMutability": "nonpayable",
219 "type": "function"
220 },
221 {
222 "inputs": [],
223 "name": "decimals",
224 "outputs": [
225 {"internalType": "uint8", "name": "", "type": "uint8"}
226 ],
227 "stateMutability": "view",
228 "type": "function"
229 },
230 {
231 "inputs": [
232 {"internalType": "address", "name": "spender", "type": "address"},
233 {"internalType": "uint256", "name": "subtractedValue", "type": "uint256"}
234 ],
235 "name": "decreaseAllowance",
236 "outputs": [
237 {"internalType": "bool", "name": "", "type": "bool"}
238 ],
239 "stateMutability": "nonpayable",
240 "type": "function"
241 },
242 {
243 "inputs": [
244 {"internalType": "address", "name": "spender", "type": "address"},
245 {"internalType": "uint256", "name": "addedValue", "type": "uint256"}
246 ],
247 "name": "increaseAllowance",
248 "outputs": [
249 {"internalType": "bool", "name": "", "type": "bool"}
250 ],
251 "stateMutability": "nonpayable",
252 "type": "function"
253 },
254 {
255 "inputs": [
256 {"internalType": "address", "name": "to", "type": "address"},
257 {"internalType": "uint256", "name": "amount", "type": "uint256"}
258 ],
259 "name": "mint",
260 "outputs": [],
261 "stateMutability": "nonpayable",
262 "type": "function"
263 },
264 {
265 "inputs": [],
266 "name": "name",
267 "outputs": [
268 {"internalType": "string", "name": "", "type": "string"}
269 ],
270 "stateMutability": "view",
271 "type": "function"
272 },
273 {
274 "inputs": [],
275 "name": "owner",
276 "outputs": [
277 {"internalType": "address", "name": "", "type": "address"}
278 ],
279 "stateMutability": "view",
280 "type": "function"
281 },
282 {
283 "inputs": [
284 {"internalType": "address", "name": "token", "type": "address"},
285 {"internalType": "uint256", "name": "value", "type": "uint256"}
286 ],
287 "name": "payToContract",
288 "outputs": [],
289 "stateMutability": "payable",
290 "type": "function"
291 },
292 {
293 "inputs": [
294 {"internalType": "uint16", "name": "order_id", "type": "uint16"},
295 {"internalType": "address", "name": "seller", "type": "address"}
296 ],
297 "name": "payWithNativeToken",
298 "outputs": [],
299 "stateMutability": "payable",
300 "type": "function"
301 },
302 {
303 "inputs": [
304 {"internalType": "string", "name": "username", "type": "string"}
305 ],
306 "name": "regiserUser",
307 "outputs": [],
308 "stateMutability": "nonpayable",
309 "type": "function"
310 },
311 {
312 "inputs": [],
313 "name": "renounceOwnership",
314 "outputs": [],
315 "stateMutability": "nonpayable",
316 "type": "function"
317 },
318 {
319 "inputs": [
320 {"internalType": "uint16", "name": "id", "type": "uint16"},
321 {"internalType": "address", "name": "buyer", "type": "address"},
322 {"internalType": "address", "name": "seller", "type": "address"}
323 ],
324 "name": "selectOrder",
325 "outputs": [
326 {"internalType": "uint232", "name": "", "type": "uint232"},
327 {"internalType": "uint16", "name": "", "type": "uint16"},
328 {"internalType": "uint8", "name": "", "type": "uint8"}
329 ],
330 "stateMutability": "view",
331 "type": "function"
332 },
333 {
334 "inputs": [],
335 "name": "symbol",
336 "outputs": [
337 {"internalType": "string", "name": "", "type": "string"}
338 ],
339 "stateMutability": "view",
340 "type": "function"
341 },
342 {
343 "inputs": [
344 {"internalType": "address", "name": "signer", "type": "address"}
345 ],
346 "name": "toggleSigner",
347 "outputs": [],
348 "stateMutability": "nonpayable",
349 "type": "function"
350 },
351 {
352 "inputs": [
353 {"internalType": "address", "name": "tokenAddress", "type": "address"}
354 ],
355 "name": "toggleToken",
356 "outputs": [],
357 "stateMutability": "nonpayable",
358 "type": "function"
359 },
360 {
361 "inputs": [],
362 "name": "totalSupply",
363 "outputs": [
364 {"internalType": "uint256", "name": "", "type": "uint256"}
365 ],
366 "stateMutability": "view",
367 "type": "function"
368 },
369 {
370 "inputs": [
371 {"internalType": "address", "name": "to", "type": "address"},
372 {"internalType": "uint256", "name": "amount", "type": "uint256"}
373 ],
374 "name": "transfer",
375 "outputs": [
376 {"internalType": "bool", "name": "", "type": "bool"}
377 ],
378 "stateMutability": "nonpayable",
379 "type": "function"
380 },
381 {
382 "inputs": [
383 {"internalType": "address", "name": "from", "type": "address"},
384 {"internalType": "address", "name": "to", "type": "address"},
385 {"internalType": "uint256", "name": "amount", "type": "uint256"}
386 ],
387 "name": "transferFrom",
388 "outputs": [
389 {"internalType": "bool", "name": "", "type": "bool"}
390 ],
391 "stateMutability": "nonpayable",
392 "type": "function"
393 },
394 {
395 "inputs": [
396 {"internalType": "address", "name": "newOwner", "type": "address"}
397 ],
398 "name": "transferOwnership",
399 "outputs": [],
400 "stateMutability": "nonpayable",
401 "type": "function"
402 },
403 {
404 "inputs": [
405 {"internalType": "uint8", "name": "newPercentage", "type": "uint8"}
406 ],
407 "name": "updateContractPercentage",
408 "outputs": [],
409 "stateMutability": "nonpayable",
410 "type": "function"
411 },
412 {
413 "inputs": [
414 {"internalType": "address[]", "name": "buyer", "type": "address[]"},
415 {"internalType": "bytes[]", "name": "signature", "type": "bytes[]"},
416 {"internalType": "uint16[]", "name": "order_id", "type": "uint16[]"},
417 {"internalType": "address", "name": "contractAddress", "type": "address"}
418 ],
419 "name": "widthrawForSellers",
420 "outputs": [],
421 "stateMutability": "nonpayable",
422 "type": "function"
423 },
424 {
425 "inputs": [
426 {"internalType": "address", "name": "seller", "type": "address"},
427 {"internalType": "bytes", "name": "signature", "type": "bytes"},
428 {"internalType": "uint16", "name": "order_id", "type": "uint16"},
429 {"internalType": "address", "name": "contractAddress", "type": "address"}
430 ],
431 "name": "widthrowForBuyers",
432 "outputs": [],
433 "stateMutability": "nonpayable",
434 "type": "function"
435 }
436 ];