tx · 98Pa2kvtNVWtCx7GjJxkoNRtdrwjSTfuZiusS9f4EsSC 3N2Tdcx5fzxJAKP5hMp9W35Cp1EFzfiJ1zG: -0.01400000 Waves 2020.11.14 09:33 [1264688] smart account 3N2Tdcx5fzxJAKP5hMp9W35Cp1EFzfiJ1zG > SELF 0.00000000 Waves
{ "type": 13, "id": "98Pa2kvtNVWtCx7GjJxkoNRtdrwjSTfuZiusS9f4EsSC", "fee": 1400000, "feeAssetId": null, "timestamp": 1605335638623, "version": 2, "chainId": 84, "sender": "3N2Tdcx5fzxJAKP5hMp9W35Cp1EFzfiJ1zG", "senderPublicKey": "9SULUbW7L2jV2nv8v48Kdzox4cZ8jEfg778yJHJpgVwM", "proofs": [ "4FsenrQ13r5sAeTGRYcT9RKPV1hg2Dr1nZsdmT9VfYatMGhSsTzSgukSegRFhguDw4fJHFGHmNFUJwcZvxnfRvcg" ], "script": "base64:AAIEAAAAAAAAAGEIAhIGCgQICAgIEgYKBAgICAgSBAoCCAgSDgoMCAgICAgIAQgICAgIEg0KCwgICAgIAQgICAgIEgUKAwgICBIECgIICBIGCgQIAQEIEgQKAggIEgMKAQgSAwoBCBIDCgEIAAAAOwAAAAAJb3JhY2xlRmVlCQEAAAAFdmFsdWUAAAABCQAEJgAAAAECAAAAIzNOMnM1UnRhSFBCZW5Dc3gyRUNjb0ZSYllIeDNub1poWFcxAAAAAAhzaWduRGFwcAkBAAAABXZhbHVlAAAAAQkABCYAAAABAgAAACMzTkMyOGhTaXZybXNUVVhhWUQxeDZMMzYySjRacFVub1RkQgAAAAALZmVlUmVjZWl2ZXICAAAAIzNOMUU2dFhkZFJvVmFSZlE5ZFEzdmc1TGFXMmZzZDhIS3ViAAAAAAtzaWduQXNzZXRJZAEAAAAg6KVqvMp3QvJwYTI1Sk9Fg7m5HuWZZxfDcerZC6EEresAAAAAC3VzZG5Bc3NldElkAQAAACAP8hwSrOTEPJrsRhqrJaiw7LoHK0bMbYhy8LXikkkBtAAAAAAMd2F2ZX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wAAAACCQEAAAALU3RyaW5nRW50cnkAAAACCQEAAAANa2V5VXNlclN0YXR1cwAAAAEFAAAAB2FkZHJlc3MFAAAAC3VzZXJSZW1vdmVkCQAETAAAAAIJAQAAAAtTdHJpbmdFbnRyeQAAAAICAAAADmxhc3RfaW52b2tlX2lkBQAAAAJpZAUAAAADbmlsCQAAAgAAAAECAAAAC05vdCBhbGxvd2VkAAAAAWkBAAAAC2RlbGV0ZUVudHJ5AAAAAQAAAAVlbnRyeQQAAAAGY2FsbGVyCQAEJQAAAAEJAQAAABRhZGRyZXNzRnJvbVB1YmxpY0tleQAAAAEIBQAAAAFpAAAAD2NhbGxlclB1YmxpY0tleQMJAAAAAAAAAgUAAAAGY2FsbGVyBQAAAAVjaHJpcwkABEwAAAACCQEAAAALRGVsZXRlRW50cnkAAAABBQAAAAVlbnRyeQUAAAADbmlsCQAAAgAAAAECAAAAAm5vAAAAAWkBAAAACmNyZWRpdFVzZXIAAAABAAAAB2FkZHJlc3MEAAAABmNhbGxlcgkABCUAAAABCQEAAAAUYWRkcmVzc0Zyb21QdWJsaWNLZXkAAAABCAUAAAABaQAAAA9jYWxsZXJQdWJsaWNLZXkEAAAAAmlkCQACWAAAAAEIBQAAAAFpAAAADXRyYW5zYWN0aW9uSWQDCQEAAAAPY29udGFpbnNFbGVtZW50AAAAAgkABEwAAAACBQAAAAVjaHJpcwkABEwAAAACBQAAAARqb2VwBQAAAANuaWwFAAAABmNhbGxlcgkABEwAAAACCQEAAAAOU2NyaXB0VHJhbnNmZXIAAAADCQEAAAAHQWRkcmVzcwAAAAEJAAJZAAAAAQUAAAAHYWRkcmVzcwAAAAAi7LJcAAUAAAALc2lnbkFzc2V0SWQFAAAAA25pbAkAAAIAAAABAgAAAAtOb3QgYWxsb3dlZAAAAABOmxgh", "height": 1264688, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: HCkiTnpN7Dgpq1tfasvXqJ1gHeDKozinbPoL1p4KimbL Next: 4tKjbNpfXA5VfZuGzfHqoAB5ooB7GQRRPAa5diZJLsEQ Diff:
Old | New | Differences | |
---|---|---|---|
297 | 297 | then (status == userAllowed) | |
298 | 298 | else false) | |
299 | 299 | then throw("User already allowed") | |
300 | - | else if (if ((currentStatus == | |
300 | + | else if (if ((currentStatus == userRegistered)) | |
301 | 301 | then (status == userAllowed) | |
302 | 302 | else false) | |
303 | - | then throw("User already allowed & verified") | |
304 | - | else if (containsElement([chris, joep], caller)) | |
305 | - | then [StringEntry(keyUserStatus(address), statusToSet), StringEntry("last_invoke_id", id)] | |
306 | - | else throw(((("Not allowed to change user status " + caller) + " / ") + chris)) | |
303 | + | then throw("User already allowed & registered") | |
304 | + | else if (if ((currentStatus == userVerified)) | |
305 | + | then (status == userAllowed) | |
306 | + | else false) | |
307 | + | then throw("User already allowed & verified") | |
308 | + | else if (containsElement([chris, joep], caller)) | |
309 | + | then [StringEntry(keyUserStatus(address), statusToSet), StringEntry("last_invoke_id", id)] | |
310 | + | else throw(((("Not allowed to change user status " + caller) + " / ") + chris)) | |
307 | 311 | } | |
308 | 312 | ||
309 | 313 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 4 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let oracleFee = value(addressFromString("3N2s5RtaHPBenCsx2ECcoFRbYHx3noZhXW1")) | |
5 | 5 | ||
6 | 6 | let signDapp = value(addressFromString("3NC28hSivrmsTUXaYD1x6L362J4ZpUnoTdB")) | |
7 | 7 | ||
8 | 8 | let feeReceiver = "3N1E6tXddRoVaRfQ9dQ3vg5LaW2fsd8HKub" | |
9 | 9 | ||
10 | 10 | let signAssetId = base58'Gf9t8FA4H3ssoZPCwrg3KwUFCci8zuUFP9ssRsUY3s6a' | |
11 | 11 | ||
12 | 12 | let usdnAssetId = base58'25FEqEjRkqK6yCkiT7Lz6SAYz7gUFCtxfCChnrVFD5AT' | |
13 | 13 | ||
14 | 14 | let wavesAssetId = base58'' | |
15 | 15 | ||
16 | 16 | let signCut = 8 | |
17 | 17 | ||
18 | 18 | let usdnCut = 10 | |
19 | 19 | ||
20 | 20 | let wavesCut = 10 | |
21 | 21 | ||
22 | 22 | let chris = "3MsG6jPNCrVJUtYB7XJBxS7utWsXAf4n9Vp" | |
23 | 23 | ||
24 | 24 | let joep = "3Mzm4VLwsN9uZwbTMzPj3XuxV6kEfAR8UDN" | |
25 | 25 | ||
26 | 26 | let WHITELISTEDONLY = true | |
27 | 27 | ||
28 | 28 | let dappRunning = true | |
29 | 29 | ||
30 | 30 | let maintenanceMSG = "SIGN Art is under maintenance" | |
31 | 31 | ||
32 | 32 | let userAllowed = "ALLOWED" | |
33 | 33 | ||
34 | 34 | let userRegistered = "REGISTERED" | |
35 | 35 | ||
36 | 36 | let userVerified = "VERIFIED" | |
37 | 37 | ||
38 | 38 | let userSuspended = "SUSPENDED" | |
39 | 39 | ||
40 | 40 | let userRemoved = "REMOVED" | |
41 | 41 | ||
42 | 42 | let userUnregistered = "UNREGISTERED" | |
43 | 43 | ||
44 | 44 | let userReset = "RESET" | |
45 | 45 | ||
46 | 46 | func getStringByKey (key) = match getString(this, key) { | |
47 | 47 | case a: String => | |
48 | 48 | a | |
49 | 49 | case _ => | |
50 | 50 | "" | |
51 | 51 | } | |
52 | 52 | ||
53 | 53 | ||
54 | 54 | func getIntegerByKeyFromOracle (key) = match getInteger(oracleFee, key) { | |
55 | 55 | case a: Int => | |
56 | 56 | a | |
57 | 57 | case _ => | |
58 | 58 | throw("Integer undefine or 0 in oracle") | |
59 | 59 | } | |
60 | 60 | ||
61 | 61 | ||
62 | 62 | func getIntegerByKey (key) = match getInteger(this, key) { | |
63 | 63 | case i: Int => | |
64 | 64 | i | |
65 | 65 | case _ => | |
66 | 66 | 0 | |
67 | 67 | } | |
68 | 68 | ||
69 | 69 | ||
70 | 70 | func getBooleanByKey (key) = match getBoolean(this, key) { | |
71 | 71 | case i: Boolean => | |
72 | 72 | i | |
73 | 73 | case _ => | |
74 | 74 | false | |
75 | 75 | } | |
76 | 76 | ||
77 | 77 | ||
78 | 78 | func checkSignCertificate (signID,Owner,sha256Hash) = match getString(signDapp, ((("data_fc_" + signID) + "_") + Owner)) { | |
79 | 79 | case a: String => | |
80 | 80 | if (contains(a, sha256Hash)) | |
81 | 81 | then true | |
82 | 82 | else false | |
83 | 83 | case _ => | |
84 | 84 | false | |
85 | 85 | } | |
86 | 86 | ||
87 | 87 | ||
88 | 88 | func validateCID (cid) = if (if ((75 > size(cid))) | |
89 | 89 | then (60 > size(split(cid, "/")[0])) | |
90 | 90 | else false) | |
91 | 91 | then (16 > size(split(cid, "/")[1])) | |
92 | 92 | else false | |
93 | 93 | ||
94 | 94 | ||
95 | 95 | func validateHash (hash) = (65 > size(hash)) | |
96 | 96 | ||
97 | 97 | ||
98 | 98 | func keyUserAddr (caller) = ("user_" + caller) | |
99 | 99 | ||
100 | 100 | ||
101 | 101 | func keyUserName (caller) = ("user_name_" + caller) | |
102 | 102 | ||
103 | 103 | ||
104 | 104 | func keyUserDesc (caller) = ("user_desc_" + caller) | |
105 | 105 | ||
106 | 106 | ||
107 | 107 | func keyUserSocial (caller) = ("user_social_" + caller) | |
108 | 108 | ||
109 | 109 | ||
110 | 110 | func keyUserThumb (caller) = ("user_thumb_" + caller) | |
111 | 111 | ||
112 | 112 | ||
113 | 113 | func keyUserStatus (caller) = ("user_status_" + caller) | |
114 | 114 | ||
115 | 115 | ||
116 | 116 | func keyUserDate (caller) = ("user_date_" + caller) | |
117 | 117 | ||
118 | 118 | ||
119 | 119 | func keyArtDate (caller,artId) = ((("art_date_" + artId) + "_") + caller) | |
120 | 120 | ||
121 | 121 | ||
122 | 122 | func keyArtName (caller,artId) = ((("art_name_" + artId) + "_") + caller) | |
123 | 123 | ||
124 | 124 | ||
125 | 125 | func keyArtDesc (caller,artId) = ((("art_desc_" + artId) + "_") + caller) | |
126 | 126 | ||
127 | 127 | ||
128 | 128 | func keyArtDisplayCid (caller,artId) = ((("art_display_cid_" + artId) + "_") + caller) | |
129 | 129 | ||
130 | 130 | ||
131 | 131 | func keyArtExportHash (caller,artId) = ((("art_export_hash_" + artId) + "_") + caller) | |
132 | 132 | ||
133 | 133 | ||
134 | 134 | func keyArtExportCid (caller,artId) = ((("art_export_cid_" + artId) + "_") + caller) | |
135 | 135 | ||
136 | 136 | ||
137 | 137 | func keyArtMaxMint (caller,artId) = ((("art_maxmint_" + artId) + "_") + caller) | |
138 | 138 | ||
139 | 139 | ||
140 | 140 | func keyArtSignID (caller,artId) = ((("art_signid_" + artId) + "_") + caller) | |
141 | 141 | ||
142 | 142 | ||
143 | 143 | func keyArtIssued (caller,artId) = ((("art_issued_" + artId) + "_") + caller) | |
144 | 144 | ||
145 | 145 | ||
146 | 146 | func keyArtOnSale (caller,artId) = ((("art_onsale_" + artId) + "_") + caller) | |
147 | 147 | ||
148 | 148 | ||
149 | 149 | func keyArtLicenceHash (caller,artId) = ((("art_licence_hash_" + artId) + "_") + caller) | |
150 | 150 | ||
151 | 151 | ||
152 | 152 | func keyArtLicenceCid (caller,artId) = ((("art_licence_cid_" + artId) + "_") + caller) | |
153 | 153 | ||
154 | 154 | ||
155 | 155 | func keyArtTags (caller,artId) = ((("art_tags_" + artId) + "_") + caller) | |
156 | 156 | ||
157 | 157 | ||
158 | 158 | func keyArtType (caller,artId) = ((("art_type_" + artId) + "_") + caller) | |
159 | 159 | ||
160 | 160 | ||
161 | 161 | func keyArtPrice (caller,artId) = ((("art_price_" + artId) + "_") + caller) | |
162 | 162 | ||
163 | 163 | ||
164 | 164 | func keyArtAssetIdAccepted (caller,artId) = ((("art_assetAccepted_" + artId) + "_") + caller) | |
165 | 165 | ||
166 | 166 | ||
167 | 167 | func keyArtFlag (caller,artId) = ((("art_flag_" + artId) + "_") + caller) | |
168 | 168 | ||
169 | 169 | ||
170 | 170 | func keyArtHashByTxidAddr (caller,txid) = ((("get_hashbytxidaddr_" + txid) + "_") + caller) | |
171 | 171 | ||
172 | 172 | ||
173 | 173 | func keyArtOwnerByHash (sha256Hash) = ("get_owner_by_hash_" + sha256Hash) | |
174 | 174 | ||
175 | 175 | ||
176 | 176 | func keyArtArtidBySignid (caller,signId) = ((("get_artidbysignid_" + signId) + "_") + caller) | |
177 | 177 | ||
178 | 178 | ||
179 | 179 | func keyArtTxidByHashOwner (sha256Hash,caller) = ("get_txid_by_hash_owner_" + toBase58String(sha256_16Kb(toBytes((sha256Hash + caller))))) | |
180 | 180 | ||
181 | 181 | ||
182 | 182 | func validateAllCID (cidDisplay,cidExport,cidLicence) = if (if ((cidDisplay != "")) | |
183 | 183 | then !(validateCID(cidDisplay)) | |
184 | 184 | else false) | |
185 | 185 | then throw("Wrong Display CID") | |
186 | 186 | else if (if ((cidExport != "")) | |
187 | 187 | then !(validateCID(cidExport)) | |
188 | 188 | else false) | |
189 | 189 | then throw("Wrong Export CID") | |
190 | 190 | else if (if ((cidLicence != "")) | |
191 | 191 | then !(validateCID(cidLicence)) | |
192 | 192 | else false) | |
193 | 193 | then throw("Wrong Licence CID") | |
194 | 194 | else true | |
195 | 195 | ||
196 | 196 | ||
197 | 197 | func validateAllHash (sha256Export,sha256Licence) = if (if ((sha256Export != "")) | |
198 | 198 | then !(validateHash(sha256Export)) | |
199 | 199 | else false) | |
200 | 200 | then throw("Export Hash 64 char. max") | |
201 | 201 | else if (if ((sha256Licence != "")) | |
202 | 202 | then !(validateHash(sha256Licence)) | |
203 | 203 | else false) | |
204 | 204 | then throw("Licence Hash 64 char. max") | |
205 | 205 | else true | |
206 | 206 | ||
207 | 207 | ||
208 | 208 | func validateString (str,max) = if ((size(str) == 0)) | |
209 | 209 | then throw("Field cannot be is empty") | |
210 | 210 | else if ((size(str) > max)) | |
211 | 211 | then throw((str + " is too long")) | |
212 | 212 | else true | |
213 | 213 | ||
214 | 214 | ||
215 | 215 | @Callable(i) | |
216 | 216 | func registerUser (name,description,thumb,social) = if (!(dappRunning)) | |
217 | 217 | then throw(maintenanceMSG) | |
218 | 218 | else { | |
219 | 219 | let caller = toString(addressFromPublicKey(i.callerPublicKey)) | |
220 | 220 | let canRegister = getStringByKey(keyUserStatus(caller)) | |
221 | 221 | let id = toBase58String(i.transactionId) | |
222 | 222 | let timestamp = lastBlock.timestamp | |
223 | 223 | if (if ((canRegister == userSuspended)) | |
224 | 224 | then true | |
225 | 225 | else (canRegister == userRemoved)) | |
226 | 226 | then throw("Account suspended/ removed.") | |
227 | 227 | else if ((canRegister == userRegistered)) | |
228 | 228 | then throw("Already registered") | |
229 | 229 | else if (if ((canRegister == "")) | |
230 | 230 | then WHITELISTEDONLY | |
231 | 231 | else false) | |
232 | 232 | then throw("Can't register, get approved first.") | |
233 | 233 | else if (if ((name == "")) | |
234 | 234 | then true | |
235 | 235 | else (description == "")) | |
236 | 236 | then throw("Name and description cannot be empty") | |
237 | 237 | else if ((size(description) > 600)) | |
238 | 238 | then throw("600 Char. max description") | |
239 | 239 | else if ((size(name) > 45)) | |
240 | 240 | then throw("45 Char. max name") | |
241 | 241 | else [IntegerEntry(keyUserDate(caller), timestamp), StringEntry(keyUserAddr(caller), ((id + "_") + toString(timestamp))), StringEntry(keyUserName(caller), name), StringEntry(keyUserDesc(caller), description), StringEntry(keyUserSocial(caller), social), StringEntry(keyUserThumb(caller), thumb), StringEntry(keyUserStatus(caller), userRegistered), StringEntry("last_invoke_id", id)] | |
242 | 242 | } | |
243 | 243 | ||
244 | 244 | ||
245 | 245 | ||
246 | 246 | @Callable(i) | |
247 | 247 | func updateUser (name,description,thumb,social) = if (!(dappRunning)) | |
248 | 248 | then throw(maintenanceMSG) | |
249 | 249 | else { | |
250 | 250 | let caller = toString(addressFromPublicKey(i.callerPublicKey)) | |
251 | 251 | let id = toBase58String(i.transactionId) | |
252 | 252 | let canUpdate = getStringByKey(keyUserStatus(caller)) | |
253 | 253 | if (if ((canUpdate == userSuspended)) | |
254 | 254 | then true | |
255 | 255 | else (canUpdate == userRemoved)) | |
256 | 256 | then throw("Account suspended/ removed.") | |
257 | 257 | else if (if ((canUpdate == "")) | |
258 | 258 | then true | |
259 | 259 | else (canUpdate == userAllowed)) | |
260 | 260 | then throw("Register first") | |
261 | 261 | else if (if ((name == "")) | |
262 | 262 | then true | |
263 | 263 | else (description == "")) | |
264 | 264 | then throw("Name & description cannot be empty") | |
265 | 265 | else if ((size(description) > 600)) | |
266 | 266 | then throw("600 Char. max for description") | |
267 | 267 | else if ((size(name) > 45)) | |
268 | 268 | then throw("45 Char. max name") | |
269 | 269 | else [StringEntry(keyUserName(caller), name), StringEntry(keyUserDesc(caller), description), StringEntry(keyUserSocial(caller), social), StringEntry(keyUserThumb(caller), thumb), StringEntry("last_invoke_id", id)] | |
270 | 270 | } | |
271 | 271 | ||
272 | 272 | ||
273 | 273 | ||
274 | 274 | @Callable(i) | |
275 | 275 | func changeUserStatus (address,status) = if (!(dappRunning)) | |
276 | 276 | then throw(maintenanceMSG) | |
277 | 277 | else { | |
278 | 278 | let caller = toString(addressFromPublicKey(i.callerPublicKey)) | |
279 | 279 | let id = toBase58String(i.transactionId) | |
280 | 280 | let currentStatus = getStringByKey(keyUserStatus(address)) | |
281 | 281 | let statusToSet = if ((status == userVerified)) | |
282 | 282 | then userVerified | |
283 | 283 | else if ((status == userRegistered)) | |
284 | 284 | then userRegistered | |
285 | 285 | else if ((status == userSuspended)) | |
286 | 286 | then userSuspended | |
287 | 287 | else if ((status == userRemoved)) | |
288 | 288 | then userRemoved | |
289 | 289 | else if ((status == userAllowed)) | |
290 | 290 | then userAllowed | |
291 | 291 | else if (if ((status == userReset)) | |
292 | 292 | then (currentStatus == userAllowed) | |
293 | 293 | else false) | |
294 | 294 | then "" | |
295 | 295 | else throw("Unknown status") | |
296 | 296 | if (if ((currentStatus == userAllowed)) | |
297 | 297 | then (status == userAllowed) | |
298 | 298 | else false) | |
299 | 299 | then throw("User already allowed") | |
300 | - | else if (if ((currentStatus == | |
300 | + | else if (if ((currentStatus == userRegistered)) | |
301 | 301 | then (status == userAllowed) | |
302 | 302 | else false) | |
303 | - | then throw("User already allowed & verified") | |
304 | - | else if (containsElement([chris, joep], caller)) | |
305 | - | then [StringEntry(keyUserStatus(address), statusToSet), StringEntry("last_invoke_id", id)] | |
306 | - | else throw(((("Not allowed to change user status " + caller) + " / ") + chris)) | |
303 | + | then throw("User already allowed & registered") | |
304 | + | else if (if ((currentStatus == userVerified)) | |
305 | + | then (status == userAllowed) | |
306 | + | else false) | |
307 | + | then throw("User already allowed & verified") | |
308 | + | else if (containsElement([chris, joep], caller)) | |
309 | + | then [StringEntry(keyUserStatus(address), statusToSet), StringEntry("last_invoke_id", id)] | |
310 | + | else throw(((("Not allowed to change user status " + caller) + " / ") + chris)) | |
307 | 311 | } | |
308 | 312 | ||
309 | 313 | ||
310 | 314 | ||
311 | 315 | @Callable(invoke) | |
312 | 316 | func addArtwork (sha256Hash,signID,name,description,tags,type,maxmint,cidDisplay,sha256Export,cidExport,sha256Licence,cidLicence) = if (!(dappRunning)) | |
313 | 317 | then throw(maintenanceMSG) | |
314 | 318 | else { | |
315 | 319 | let artId = toBase58String(invoke.transactionId) | |
316 | 320 | let caller = toBase58String(invoke.caller.bytes) | |
317 | 321 | if (!(validateAllCID(cidDisplay, cidExport, cidLicence))) | |
318 | 322 | then throw("Problem with CID") | |
319 | 323 | else if (!(validateHash(sha256Hash))) | |
320 | 324 | then throw("Hash should be 64 characters maximum") | |
321 | 325 | else if (!(validateAllHash(sha256Export, sha256Licence))) | |
322 | 326 | then throw("Problem with Hashes") | |
323 | 327 | else if ((size(invoke.payments) == 0)) | |
324 | 328 | then throw("No payment attached") | |
325 | 329 | else { | |
326 | 330 | let payment = value(invoke.payments[0]) | |
327 | 331 | let amount = value(payment.amount) | |
328 | 332 | let assetId = if (if (isDefined(payment.assetId)) | |
329 | 333 | then (payment.assetId == signAssetId) | |
330 | 334 | else false) | |
331 | 335 | then payment.assetId | |
332 | 336 | else throw("Only SIGN token accepted at the moment") | |
333 | 337 | let currentCertificationPrice = getIntegerByKeyFromOracle(("certification_fee_" + toBase58String(signAssetId))) | |
334 | 338 | if ((amount != currentCertificationPrice)) | |
335 | 339 | then throw(("Payment amount should be " + toString(currentCertificationPrice))) | |
336 | 340 | else { | |
337 | 341 | let entryExist = getStringByKey(keyArtTxidByHashOwner(sha256Hash, caller)) | |
338 | 342 | if ((entryExist != "")) | |
339 | 343 | then throw("You already added it") | |
340 | 344 | else { | |
341 | 345 | let hashExist = getStringByKey(keyArtOwnerByHash(sha256Hash)) | |
342 | 346 | if ((hashExist != "")) | |
343 | 347 | then throw("Hash already registered") | |
344 | 348 | else { | |
345 | 349 | let isSignCertified = checkSignCertificate(signID, caller, sha256Hash) | |
346 | 350 | if (!(isSignCertified)) | |
347 | 351 | then throw("Sign Certificate not found for this address.") | |
348 | 352 | else if ((size(cidDisplay) == 0)) | |
349 | 353 | then throw("Display CID cannot be empty") | |
350 | 354 | else if (!(validateString(name, 100))) | |
351 | 355 | then throw("100 Char. max name") | |
352 | 356 | else if (!(validateString(description, 1000))) | |
353 | 357 | then throw("1000 Char. max description") | |
354 | 358 | else if ((size(split(tags, ",")) > 5)) | |
355 | 359 | then throw("5 tags max.") | |
356 | 360 | else { | |
357 | 361 | let userIsRegistered = match getString(this, ("user_status_" + caller)) { | |
358 | 362 | case s: String => | |
359 | 363 | s | |
360 | 364 | case _ => | |
361 | 365 | userUnregistered | |
362 | 366 | } | |
363 | 367 | let timestamp = lastBlock.timestamp | |
364 | 368 | if (if (isDefined(userIsRegistered)) | |
365 | 369 | then (userIsRegistered == userUnregistered) | |
366 | 370 | else false) | |
367 | 371 | then throw("Register this account first with \"User infos\" tab") | |
368 | 372 | else if ((userIsRegistered == userSuspended)) | |
369 | 373 | then throw("Account suspended") | |
370 | 374 | else if ((userIsRegistered == userRemoved)) | |
371 | 375 | then throw("Account removed") | |
372 | 376 | else if ((maxmint > 10)) | |
373 | 377 | then throw("10 editions max") | |
374 | 378 | else if ((size(sha256Hash) != 64)) | |
375 | 379 | then throw("Hash 64 char. max") | |
376 | 380 | else [StringEntry(keyArtOwnerByHash(sha256Hash), caller), StringEntry(keyArtTxidByHashOwner(sha256Hash, caller), artId), IntegerEntry(keyArtDate(caller, artId), timestamp), StringEntry(keyArtName(caller, artId), name), StringEntry(keyArtDesc(caller, artId), description), StringEntry(keyArtDisplayCid(caller, artId), cidDisplay), StringEntry(keyArtExportCid(caller, artId), cidExport), StringEntry(keyArtExportHash(caller, artId), sha256Export), StringEntry(keyArtLicenceHash(caller, artId), sha256Licence), StringEntry(keyArtLicenceCid(caller, artId), cidLicence), StringEntry(keyArtType(caller, artId), type), StringEntry(keyArtTags(caller, artId), tags), IntegerEntry(keyArtMaxMint(caller, artId), maxmint), StringEntry(keyArtSignID(caller, artId), signID), IntegerEntry(keyArtIssued(caller, artId), 0), BooleanEntry(keyArtOnSale(caller, artId), false), StringEntry(keyArtArtidBySignid(caller, signID), artId), StringEntry("last_invoke_id", artId), StringEntry(keyArtHashByTxidAddr(caller, artId), sha256Hash), ScriptTransfer(Address(fromBase58String(feeReceiver)), amount, assetId)] | |
377 | 381 | } | |
378 | 382 | } | |
379 | 383 | } | |
380 | 384 | } | |
381 | 385 | } | |
382 | 386 | } | |
383 | 387 | ||
384 | 388 | ||
385 | 389 | ||
386 | 390 | @Callable(invoke) | |
387 | 391 | func updateArtwork (txid,name,description,tags,type,maxmint,cidDisplay,sha256Export,cidExport,sha256Licence,cidLicence) = if (!(dappRunning)) | |
388 | 392 | then throw(maintenanceMSG) | |
389 | 393 | else { | |
390 | 394 | let updateId = toBase58String(invoke.transactionId) | |
391 | 395 | let caller = toBase58String(invoke.caller.bytes) | |
392 | 396 | if (!(validateAllCID(cidDisplay, cidExport, cidLicence))) | |
393 | 397 | then throw("Problem with CID") | |
394 | 398 | else if (!(validateAllHash(sha256Export, sha256Licence))) | |
395 | 399 | then throw("Problem with Hashes") | |
396 | 400 | else { | |
397 | 401 | let entryExist = getStringByKey(keyArtName(caller, txid)) | |
398 | 402 | if ((entryExist == "")) | |
399 | 403 | then throw("Entry not found") | |
400 | 404 | else if (!(validateString(name, 100))) | |
401 | 405 | then throw("100 Char. max name") | |
402 | 406 | else if (!(validateString(description, 1000))) | |
403 | 407 | then throw("1000 Char. max description") | |
404 | 408 | else { | |
405 | 409 | let flag = getStringByKey(keyArtFlag(caller, txid)) | |
406 | 410 | if ((flag == "ILLEGAL")) | |
407 | 411 | then throw("Cannot update") | |
408 | 412 | else { | |
409 | 413 | let artworkMinted = match getInteger(this, keyArtIssued(caller, txid)) { | |
410 | 414 | case b: Int => | |
411 | 415 | if ((b == 0)) | |
412 | 416 | then false | |
413 | 417 | else true | |
414 | 418 | case _ => | |
415 | 419 | false | |
416 | 420 | } | |
417 | 421 | if ((size(split(tags, ",")) > 5)) | |
418 | 422 | then throw("5 tags max.") | |
419 | 423 | else { | |
420 | 424 | let userIsRegistered = match getString(this, ("user_status_" + caller)) { | |
421 | 425 | case s: String => | |
422 | 426 | s | |
423 | 427 | case _ => | |
424 | 428 | userUnregistered | |
425 | 429 | } | |
426 | 430 | if (if (isDefined(userIsRegistered)) | |
427 | 431 | then (userIsRegistered == userUnregistered) | |
428 | 432 | else false) | |
429 | 433 | then throw("Register first with \"User infos\"") | |
430 | 434 | else if ((userIsRegistered == userSuspended)) | |
431 | 435 | then throw("Account suspended") | |
432 | 436 | else if ((userIsRegistered == userRemoved)) | |
433 | 437 | then throw("Account removed") | |
434 | 438 | else if ((maxmint > 10)) | |
435 | 439 | then throw("10 editions max per artwork") | |
436 | 440 | else if (!(artworkMinted)) | |
437 | 441 | then [StringEntry(keyArtName(caller, txid), name), StringEntry(keyArtDesc(caller, txid), description), StringEntry(keyArtDisplayCid(caller, txid), cidDisplay), StringEntry(keyArtExportCid(caller, txid), cidExport), StringEntry(keyArtExportHash(caller, txid), sha256Export), StringEntry(keyArtLicenceCid(caller, txid), cidLicence), StringEntry(keyArtLicenceHash(caller, txid), sha256Licence), IntegerEntry(keyArtMaxMint(caller, txid), maxmint), StringEntry(keyArtTags(caller, txid), tags), StringEntry(keyArtType(caller, txid), type), StringEntry("last_invoke_id", updateId)] | |
438 | 442 | else throw("Already minted") | |
439 | 443 | } | |
440 | 444 | } | |
441 | 445 | } | |
442 | 446 | } | |
443 | 447 | } | |
444 | 448 | ||
445 | 449 | ||
446 | 450 | ||
447 | 451 | @Callable(i) | |
448 | 452 | func flagArtwork (artId,addr,flag) = { | |
449 | 453 | let caller = toString(addressFromPublicKey(i.callerPublicKey)) | |
450 | 454 | let id = toBase58String(i.transactionId) | |
451 | 455 | if (containsElement([chris, joep], caller)) | |
452 | 456 | then if ((flag == "CONSENT")) | |
453 | 457 | then [StringEntry(keyArtFlag(addr, artId), flag), StringEntry("last_invoke_id", id)] | |
454 | 458 | else if ((flag == "")) | |
455 | 459 | then [StringEntry(keyArtFlag(addr, artId), flag), StringEntry("last_invoke_id", id)] | |
456 | 460 | else if ((flag == "ILLEGAL")) | |
457 | 461 | then [StringEntry(keyArtFlag(addr, artId), flag), StringEntry(keyArtName(addr, artId), "ILLEGAL CONTENT"), StringEntry(keyArtDesc(addr, artId), "ILLEGAL CONTENT"), StringEntry(keyArtDisplayCid(addr, artId), ""), StringEntry(keyArtExportCid(addr, artId), ""), StringEntry(keyArtLicenceCid(addr, artId), ""), StringEntry("last_invoke_id", id)] | |
458 | 462 | else throw(("Unknow status" + flag)) | |
459 | 463 | else throw("no") | |
460 | 464 | } | |
461 | 465 | ||
462 | 466 | ||
463 | 467 | ||
464 | 468 | @Callable(i) | |
465 | 469 | func deleteArtwork (artId,addr) = { | |
466 | 470 | let caller = toString(addressFromPublicKey(i.callerPublicKey)) | |
467 | 471 | let id = toBase58String(i.transactionId) | |
468 | 472 | let addressToUse = if (containsElement([chris, joep], caller)) | |
469 | 473 | then addr | |
470 | 474 | else caller | |
471 | 475 | let entryExist = match getString(this, keyArtName(addressToUse, artId)) { | |
472 | 476 | case s: String => | |
473 | 477 | s | |
474 | 478 | case _ => | |
475 | 479 | throw("No art matching") | |
476 | 480 | } | |
477 | 481 | let artworkMinted = match getInteger(this, keyArtIssued(addressToUse, artId)) { | |
478 | 482 | case b: Int => | |
479 | 483 | if ((b != 0)) | |
480 | 484 | then true | |
481 | 485 | else false | |
482 | 486 | case _ => | |
483 | 487 | false | |
484 | 488 | } | |
485 | 489 | let maxMint = getIntegerByKey(keyArtMaxMint(addressToUse, artId)) | |
486 | 490 | let sha256Hash = match getString(this, keyArtHashByTxidAddr(addressToUse, artId)) { | |
487 | 491 | case s: String => | |
488 | 492 | s | |
489 | 493 | case _ => | |
490 | 494 | throw("No art hash matching") | |
491 | 495 | } | |
492 | 496 | let signID = match getString(this, keyArtSignID(addressToUse, artId)) { | |
493 | 497 | case s: String => | |
494 | 498 | s | |
495 | 499 | case _ => | |
496 | 500 | throw("No SIGN ID matching") | |
497 | 501 | } | |
498 | 502 | let dataToDelete = [DeleteEntry(keyArtDate(addressToUse, artId)), DeleteEntry(keyArtName(addressToUse, artId)), DeleteEntry(keyArtDesc(addressToUse, artId)), DeleteEntry(keyArtDisplayCid(addressToUse, artId)), DeleteEntry(keyArtExportCid(addressToUse, artId)), DeleteEntry(keyArtExportHash(addressToUse, artId)), DeleteEntry(keyArtLicenceHash(addressToUse, artId)), DeleteEntry(keyArtLicenceCid(addressToUse, artId)), DeleteEntry(keyArtType(addressToUse, artId)), DeleteEntry(keyArtTags(addressToUse, artId)), DeleteEntry(keyArtMaxMint(addressToUse, artId)), DeleteEntry(keyArtSignID(addressToUse, artId)), DeleteEntry(keyArtIssued(addressToUse, artId)), DeleteEntry(keyArtOnSale(addressToUse, artId)), DeleteEntry(keyArtFlag(addr, artId)), StringEntry("last_invoke_id", id), DeleteEntry(keyArtOwnerByHash(sha256Hash)), DeleteEntry(keyArtArtidBySignid(addressToUse, signID)), DeleteEntry(keyArtTxidByHashOwner(sha256Hash, addressToUse))] | |
499 | 503 | if (!(artworkMinted)) | |
500 | 504 | then if (!(dappRunning)) | |
501 | 505 | then throw(maintenanceMSG) | |
502 | 506 | else dataToDelete | |
503 | 507 | else throw("Art already minted, cannot delete") | |
504 | 508 | } | |
505 | 509 | ||
506 | 510 | ||
507 | 511 | ||
508 | 512 | @Callable(i) | |
509 | 513 | func sellArtwork (artId,price,maxMint,assetId) = if (!(dappRunning)) | |
510 | 514 | then throw(maintenanceMSG) | |
511 | 515 | else { | |
512 | 516 | let id = toBase58String(i.transactionId) | |
513 | 517 | let caller = toBase58String(i.caller.bytes) | |
514 | 518 | let sellDate = lastBlock.timestamp | |
515 | 519 | let exportCID = getStringByKey(keyArtExportCid(caller, artId)) | |
516 | 520 | if ((size(split(exportCID, "/")[0]) != 59)) | |
517 | 521 | then throw("You cannot sell art with no export file") | |
518 | 522 | else { | |
519 | 523 | let exportHash = getStringByKey(keyArtExportHash(caller, artId)) | |
520 | 524 | if ((size(exportHash) != 64)) | |
521 | 525 | then throw("You cannot sell art with no export hash") | |
522 | 526 | else if (if (if ((assetId != toBase58String(signAssetId))) | |
523 | 527 | then (assetId != toBase58String(wavesAssetId)) | |
524 | 528 | else false) | |
525 | 529 | then (assetId != toBase58String(usdnAssetId)) | |
526 | 530 | else false) | |
527 | 531 | then throw("Only SIGN, USDN or WAVES accepted") | |
528 | 532 | else { | |
529 | 533 | let minSellWaves = getIntegerByKeyFromOracle("waves_min_sell") | |
530 | 534 | let minSellUsdn = 1000000 | |
531 | 535 | let minSellSign = (getIntegerByKeyFromOracle(("certification_fee_" + toBase58String(signAssetId))) * 2) | |
532 | 536 | if (if (if (if (if ((assetId == toBase58String(usdnAssetId))) | |
533 | 537 | then (minSellUsdn > price) | |
534 | 538 | else false) | |
535 | 539 | then (price != 0) | |
536 | 540 | else false) | |
537 | 541 | then true | |
538 | 542 | else if (if ((assetId == toBase58String(signAssetId))) | |
539 | 543 | then (minSellSign > price) | |
540 | 544 | else false) | |
541 | 545 | then (price != 0) | |
542 | 546 | else false) | |
543 | 547 | then true | |
544 | 548 | else if (if ((assetId == toBase58String(wavesAssetId))) | |
545 | 549 | then (minSellWaves > price) | |
546 | 550 | else false) | |
547 | 551 | then (price != 0) | |
548 | 552 | else false) | |
549 | 553 | then throw("Wrong minimum sell price") | |
550 | 554 | else { | |
551 | 555 | let artworkName = match getString(this, keyArtName(caller, artId)) { | |
552 | 556 | case s: String => | |
553 | 557 | s | |
554 | 558 | case _ => | |
555 | 559 | throw("This art doesn't match") | |
556 | 560 | } | |
557 | 561 | let userIsRegistered = match getString(this, keyUserStatus(caller)) { | |
558 | 562 | case s: String => | |
559 | 563 | s | |
560 | 564 | case _ => | |
561 | 565 | throw("Register this account first") | |
562 | 566 | } | |
563 | 567 | let amountSold = getIntegerByKey(keyArtIssued(caller, artId)) | |
564 | 568 | let maxCanSell = getIntegerByKey(keyArtMaxMint(caller, artId)) | |
565 | 569 | if (if ((amountSold != 0)) | |
566 | 570 | then (amountSold == maxCanSell) | |
567 | 571 | else false) | |
568 | 572 | then throw("Max edition reached.") | |
569 | 573 | else if (if ((amountSold > 0)) | |
570 | 574 | then (maxCanSell != maxMint) | |
571 | 575 | else false) | |
572 | 576 | then throw("Cannot change maximum issuable anymore") | |
573 | 577 | else if ((userIsRegistered == userSuspended)) | |
574 | 578 | then throw("Account suspended") | |
575 | 579 | else if ((userIsRegistered == userRemoved)) | |
576 | 580 | then throw("Account deleted") | |
577 | 581 | else { | |
578 | 582 | let sellStatus = if ((price > 0)) | |
579 | 583 | then true | |
580 | 584 | else false | |
581 | 585 | [BooleanEntry(keyArtOnSale(caller, artId), sellStatus), IntegerEntry(keyArtPrice(caller, artId), price), IntegerEntry(keyArtMaxMint(caller, artId), maxMint), StringEntry(keyArtAssetIdAccepted(caller, artId), assetId), StringEntry("last_invoke_id", id)] | |
582 | 586 | } | |
583 | 587 | } | |
584 | 588 | } | |
585 | 589 | } | |
586 | 590 | } | |
587 | 591 | ||
588 | 592 | ||
589 | 593 | ||
590 | 594 | @Callable(i) | |
591 | 595 | func buyArtwork (artId,issuer) = if (!(dappRunning)) | |
592 | 596 | then throw(maintenanceMSG) | |
593 | 597 | else { | |
594 | 598 | let id = toBase58String(i.transactionId) | |
595 | 599 | let caller = toBase58String(i.caller.bytes) | |
596 | 600 | let totalNFT = getIntegerByKey("total_nft_issued") | |
597 | 601 | let signID = getStringByKey(keyArtSignID(issuer, artId)) | |
598 | 602 | let artworkName = match getString(this, keyArtName(issuer, artId)) { | |
599 | 603 | case s: String => | |
600 | 604 | s | |
601 | 605 | case _ => | |
602 | 606 | throw("Art doesn't exist") | |
603 | 607 | } | |
604 | 608 | let displayCID = getStringByKey(keyArtDisplayCid(issuer, artId)) | |
605 | 609 | let exportCID = getStringByKey(keyArtExportCid(issuer, artId)) | |
606 | 610 | let exportHash = getStringByKey(keyArtExportHash(issuer, artId)) | |
607 | 611 | let licenceCID = getStringByKey(keyArtLicenceCid(issuer, artId)) | |
608 | 612 | let licenceHash = getStringByKey(keyArtLicenceHash(issuer, artId)) | |
609 | 613 | let description = take(getStringByKey(keyArtDesc(issuer, artId)), 50) | |
610 | 614 | let amountSold = getIntegerByKey(keyArtIssued(issuer, artId)) | |
611 | 615 | let artworkPrice = getIntegerByKey(keyArtPrice(issuer, artId)) | |
612 | 616 | let isOnSale = getBooleanByKey(keyArtOnSale(issuer, artId)) | |
613 | 617 | let priceAssetId = getStringByKey(keyArtAssetIdAccepted(issuer, artId)) | |
614 | 618 | let sourceHash = getStringByKey(keyArtHashByTxidAddr(issuer, artId)) | |
615 | 619 | if ((artworkPrice == 0)) | |
616 | 620 | then throw("Art not for sell") | |
617 | 621 | else if (!(isOnSale)) | |
618 | 622 | then throw("Art not for sale") | |
619 | 623 | else { | |
620 | 624 | let maxCanSell = getIntegerByKey(keyArtMaxMint(issuer, artId)) | |
621 | 625 | let payment = value(i.payments[0]) | |
622 | 626 | let amount = value(payment.amount) | |
623 | 627 | let assetId = if (if (if (isDefined(payment.assetId)) | |
624 | 628 | then (size(fromBase58String(priceAssetId)) > 0) | |
625 | 629 | else false) | |
626 | 630 | then (payment.assetId == fromBase58String(priceAssetId)) | |
627 | 631 | else false) | |
628 | 632 | then payment.assetId | |
629 | 633 | else unit | |
630 | 634 | let cut = if ((priceAssetId == toBase58String(signAssetId))) | |
631 | 635 | then 8 | |
632 | 636 | else 10 | |
633 | 637 | let amountForSign = fraction(amount, cut, 100) | |
634 | 638 | let amountForCreator = (amount - amountForSign) | |
635 | 639 | if ((amountSold == maxCanSell)) | |
636 | 640 | then throw("Art sold out") | |
637 | 641 | else if ((artworkPrice != amount)) | |
638 | 642 | then throw("Payment don't match") | |
639 | 643 | else { | |
640 | 644 | let newAmountSold = (amountSold + 1) | |
641 | 645 | let entryDate = lastBlock.timestamp | |
642 | 646 | let issueMeta = (((((((((((((((((((((((((((("{\"version\": 1, | |
643 | 647 | \"creator\": \"" + issuer) + "\", | |
644 | 648 | \"artID\": \"") + artId) + "\", | |
645 | 649 | \"signID\": \"") + signID) + "\", | |
646 | 650 | \"artwork_name\": \"") + artworkName) + "\", | |
647 | 651 | \"artwork_desc\": \"") + description) + "\", | |
648 | 652 | \"issue\": \"") + toString(newAmountSold)) + "/") + toString(maxCanSell)) + "\", | |
649 | 653 | \"maxIssuable\": \"") + toString(maxCanSell)) + "\", | |
650 | 654 | \"source_hash\": \"") + sourceHash) + "\", | |
651 | 655 | \"display_cid\": \"") + displayCID) + "\", | |
652 | 656 | \"export_cid\": \"") + exportCID) + "\", | |
653 | 657 | \"export_hash\": \"") + exportHash) + "\", | |
654 | 658 | \"licence_cid\": \"") + licenceCID) + "\", | |
655 | 659 | \"licence_hash\": \"") + licenceHash) + "\"}") | |
656 | 660 | let issueNFT = Issue(("SA_" + toString((totalNFT + 1))), issueMeta, 1, 0, false) | |
657 | 661 | let idNFT = calculateAssetId(issueNFT) | |
658 | 662 | let sellStatus = if ((newAmountSold == maxCanSell)) | |
659 | 663 | then false | |
660 | 664 | else true | |
661 | 665 | [IntegerEntry(keyArtIssued(issuer, artId), newAmountSold), StringEntry(((((((("art_sold_" + toString(newAmountSold)) + "_of_") + toString(maxCanSell)) + "_") + artId) + "_") + issuer), ((((((((((caller + "_") + toString(entryDate)) + "_") + id) + "_") + toString(artworkPrice)) + "_") + priceAssetId) + "_") + toBase58String(idNFT))), IntegerEntry("total_nft_issued", (totalNFT + 1)), BooleanEntry(keyArtOnSale(issuer, artId), sellStatus), StringEntry("last_invoke_id", id), issueNFT, ScriptTransfer(Address(fromBase58String(issuer)), amountForCreator, assetId), ScriptTransfer(Address(fromBase58String(feeReceiver)), amountForSign, assetId), ScriptTransfer(i.caller, 1, idNFT)] | |
662 | 666 | } | |
663 | 667 | } | |
664 | 668 | } | |
665 | 669 | ||
666 | 670 | ||
667 | 671 | ||
668 | 672 | @Callable(i) | |
669 | 673 | func deleteUser (address) = { | |
670 | 674 | let caller = toString(addressFromPublicKey(i.callerPublicKey)) | |
671 | 675 | let id = toBase58String(i.transactionId) | |
672 | 676 | if (containsElement([chris, joep], caller)) | |
673 | 677 | then [DeleteEntry(keyUserDate(address)), DeleteEntry(keyUserAddr(address)), DeleteEntry(keyUserName(address)), DeleteEntry(keyUserDesc(address)), DeleteEntry(keyUserSocial(address)), DeleteEntry(keyUserThumb(address)), StringEntry(keyUserStatus(address), userRemoved), StringEntry("last_invoke_id", id)] | |
674 | 678 | else throw("Not allowed") | |
675 | 679 | } | |
676 | 680 | ||
677 | 681 | ||
678 | 682 | ||
679 | 683 | @Callable(i) | |
680 | 684 | func deleteEntry (entry) = { | |
681 | 685 | let caller = toString(addressFromPublicKey(i.callerPublicKey)) | |
682 | 686 | if ((caller == chris)) | |
683 | 687 | then [DeleteEntry(entry)] | |
684 | 688 | else throw("no") | |
685 | 689 | } | |
686 | 690 | ||
687 | 691 | ||
688 | 692 | ||
689 | 693 | @Callable(i) | |
690 | 694 | func creditUser (address) = { | |
691 | 695 | let caller = toString(addressFromPublicKey(i.callerPublicKey)) | |
692 | 696 | let id = toBase58String(i.transactionId) | |
693 | 697 | if (containsElement([chris, joep], caller)) | |
694 | 698 | then [ScriptTransfer(Address(fromBase58String(address)), 150000000000, signAssetId)] | |
695 | 699 | else throw("Not allowed") | |
696 | 700 | } | |
697 | 701 | ||
698 | 702 |
github/deemru/w8io/026f985 93.85 ms ◑