tx · CmsnHAQ3nK9sECHusTnnVcg34oviHzneKgnVDgW2hPtz 3NBynfbXC2KastUxhukcMUaE58K9cBdB9UY: -0.02500000 Waves 2023.09.13 12:14 [2753429] smart account 3NBynfbXC2KastUxhukcMUaE58K9cBdB9UY > SELF 0.00000000 Waves
{ "type": 13, "id": "CmsnHAQ3nK9sECHusTnnVcg34oviHzneKgnVDgW2hPtz", "fee": 2500000, "feeAssetId": null, "timestamp": 1694596465941, "version": 2, "chainId": 84, "sender": "3NBynfbXC2KastUxhukcMUaE58K9cBdB9UY", "senderPublicKey": "J9DCtJJxJBWZdtDR12BA1U94Q3cZzMi4R6k5hYkAzmzC", "proofs": [ "2csLVH93R2qeukFD1Q4tGggyyYFwYcAf31zBqz5kGk49P9wiQqV7E5Hr9e4uWct7mS1RasMSzndSb1qFKbJ1C5tN" ], "script": "base64:BgJeCAISBAoCCAgSDgoMCAgICAgICAgICAEIEg8KDQgICAgICAgICAgIAQgSBgoECAgICBIECgIICBIICgYIAQEIAQgSBAoCCAgSBAoCCAgSBwoFCAgICAgSBgoECAgICFkAB1ZFUlNJT04CBTIuMC4wAQ5nZXRTdHJpbmdCeUtleQEDa2V5CQELdmFsdWVPckVsc2UCCQCdCAIFBHRoaXMFA2tleQIAAAh1bml0VGVzdAcACW9yYWNsZUZlZQkBBXZhbHVlAQkApggBCQEOZ2V0U3RyaW5nQnlLZXkBAg9jb25mX29yYWNsZV9mZWUACHNpZ25EYXBwCQEFdmFsdWUBCQCmCAEJAQ5nZXRTdHJpbmdCeUtleQECEWNvbmZfc2lnbndlYl9kYXBwAAtmZWVSZWNlaXZlcgkBDmdldFN0cmluZ0J5S2V5AQIRY29uZl9mZWVfcmVjZWl2ZXIACHVzZXJEYXBwAwUIdW5pdFRlc3QJAQV2YWx1ZQEJAKYIAQIjM010NFJHTUV5alNXWUFvY1RQcWQ1NXdkSFFRQjNQVTJVQ20JAQV2YWx1ZQEJAKYIAQkBDmdldFN0cmluZ0J5S2V5AQIPY29uZl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BnByb29mcwAACQDZBAEJAQhhc1N0cmluZwEJAJEDAggFA2ludgRhcmdzAAsDAwMDCQAAAggFA2ludghmdW5jdGlvbgINdXBkYXRlQXJ0d29yawkAAAIIBQNpbnYEZEFwcAUEdGhpcwcJAAACCAUDaW52A2ZlZQCgwh4HCQAAAggFA2ludgpmZWVBc3NldElkBQR1bml0BwkA9AMDCAUCdHgJYm9keUJ5dGVzCQCRAwIIBQJ0eAZwcm9vZnMAAAkA2QQBCQEIYXNTdHJpbmcBCQCRAwIIBQNpbnYEYXJncwAMAwMDAwkAAAIIBQNpbnYIZnVuY3Rpb24CC3NlbGxBcnR3b3JrCQAAAggFA2ludgRkQXBwBQR0aGlzBwkAAAIIBQNpbnYDZmVlAKDCHgcJAAACCAUDaW52CmZlZUFzc2V0SWQFBHVuaXQHCQD0AwMIBQJ0eAlib2R5Qnl0ZXMJAJEDAggFAnR4BnByb29mcwAACQDZBAEJAQhhc1N0cmluZwEJAJEDAggFA2ludgRhcmdzAAUDAwMDCQAAAggFA2ludghmdW5jdGlvbgIJYWNjZXB0QmlkCQAAAggFA2ludgRkQXBwBQR0aGlzBwkAAAIIBQNpbnYDZmVlAKDCHgcJAAACCAUDaW52CmZlZUFzc2V0SWQFBHVuaXQHCQDIEwMIBQJ0eAlib2R5Qnl0ZXMJAJEDAggFAnR4BnByb29mcwAACQDZBAEJAQhhc1N0cmluZwEJAJEDAggFA2ludgRhcmdzAAQJAPQDAwgFAnR4CWJvZHlCeXRlcwkAkQMCCAUCdHgGcHJvb2ZzAAAIBQJ0eA9zZW5kZXJQdWJsaWNLZXkJAPQDAwgFAnR4CWJvZHlCeXRlcwkAkQMCCAUCdHgGcHJvb2ZzAAAIBQJ0eA9zZW5kZXJQdWJsaWNLZXmFcW54", "height": 2753429, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: CDxpDMUEM8Sha7yAfHJjRsMKNbiSv4bnjU9FpGdo4yQb Next: GsV3nboydm8e3U2tc3Vvc5pxuiWnv1PTNBkMzuwijk5r Diff:
Old | New | Differences | |
---|---|---|---|
20 | 20 | ||
21 | 21 | let i = value(addressFromString(b("conf_whitelist_dapp"))) | |
22 | 22 | ||
23 | - | let j = | |
23 | + | let j = b("conf_accepted_asset_USDT_PP") | |
24 | 24 | ||
25 | - | let k = | |
25 | + | let k = b("conf_accepted_asset_ART") | |
26 | 26 | ||
27 | - | let l = | |
27 | + | let l = b("conf_accepted_asset_USDC_PP") | |
28 | 28 | ||
29 | - | let m = | |
29 | + | let m = b("conf_accepted_asset_EAST") | |
30 | 30 | ||
31 | - | let n = | |
31 | + | let n = b("conf_accepted_asset_PUZZLE") | |
32 | 32 | ||
33 | - | let o = b("conf_ | |
33 | + | let o = b("conf_accepted_asset_ETH_PP") | |
34 | 34 | ||
35 | - | func p (c) = valueOrErrorMessage(getInteger(e, c), "Integer undefine or 0 in oracle") | |
35 | + | let p = "WAVES" | |
36 | + | ||
37 | + | let q = fromBase58String(j) | |
38 | + | ||
39 | + | let r = fromBase58String(k) | |
40 | + | ||
41 | + | let s = fromBase58String(l) | |
42 | + | ||
43 | + | let t = fromBase58String(m) | |
44 | + | ||
45 | + | let u = fromBase58String(n) | |
46 | + | ||
47 | + | let v = fromBase58String(o) | |
48 | + | ||
49 | + | let w = base58'' | |
50 | + | ||
51 | + | let x = [j, k, l, m, n, p, o] | |
52 | + | ||
53 | + | let y = b("conf_admin_1") | |
54 | + | ||
55 | + | func z (c) = valueOrErrorMessage(getInteger(e, c), "Integer undefine or 0 in oracle") | |
36 | 56 | ||
37 | 57 | ||
38 | - | func | |
58 | + | func A (c) = valueOrElse(getInteger(this, c), 0) | |
39 | 59 | ||
40 | 60 | ||
41 | - | func | |
61 | + | func B (c) = valueOrElse(getInteger(i, c), 0) | |
42 | 62 | ||
43 | 63 | ||
44 | - | func | |
64 | + | func C (c) = valueOrElse(getBoolean(this, c), false) | |
45 | 65 | ||
46 | 66 | ||
47 | - | let | |
67 | + | let D = 8 | |
48 | 68 | ||
49 | - | let | |
69 | + | let E = b("conf_default_licence") | |
50 | 70 | ||
51 | - | let | |
71 | + | let F = b("conf_default_licence_hash") | |
52 | 72 | ||
53 | - | let | |
73 | + | let G = valueOrElse(getBoolean(h, "conf_dapp_is_running"), true) | |
54 | 74 | ||
55 | - | let | |
75 | + | let H = valueOrElse(getString(h, "conf_maintenance_msg"), "") | |
56 | 76 | ||
57 | - | let | |
77 | + | let I = "SUSPENDED" | |
58 | 78 | ||
59 | - | let | |
79 | + | let J = "REMOVED" | |
60 | 80 | ||
61 | - | let | |
81 | + | let K = "UNREGISTERED" | |
62 | 82 | ||
63 | - | let | |
83 | + | let L = "ALLOWED" | |
64 | 84 | ||
65 | - | let | |
85 | + | let M = z(("certification_fee_" + toBase58String(r))) | |
66 | 86 | ||
67 | - | func | |
87 | + | func N (c) = valueOrElse(getInteger(this, c), 1000) | |
68 | 88 | ||
69 | 89 | ||
70 | - | func E (F,G,H) = { | |
71 | - | let I = getString(f, ((("data_fc_" + F) + "_") + G)) | |
72 | - | if ($isInstanceOf(I, "String")) | |
90 | + | func O (P) = if (contains(P, "/")) | |
91 | + | then if (if ((76 > size(P))) | |
92 | + | then (size(split(P, "/")[0]) == 59) | |
93 | + | else false) | |
94 | + | then (16 > size(split(P, "/")[1])) | |
95 | + | else false | |
96 | + | else false | |
97 | + | ||
98 | + | ||
99 | + | func Q (R) = (size(R) == 64) | |
100 | + | ||
101 | + | ||
102 | + | func S (T) = ("user_status_" + T) | |
103 | + | ||
104 | + | ||
105 | + | func U (T,V) = ((("art_date_" + V) + "_") + T) | |
106 | + | ||
107 | + | ||
108 | + | func W (T,V) = ((("art_name_" + V) + "_") + T) | |
109 | + | ||
110 | + | ||
111 | + | func X (T,V) = ((("art_desc_" + V) + "_") + T) | |
112 | + | ||
113 | + | ||
114 | + | func Y (T,V) = ((("art_display_cid_" + V) + "_") + T) | |
115 | + | ||
116 | + | ||
117 | + | func Z (T,V) = ((("art_export_hash_" + V) + "_") + T) | |
118 | + | ||
119 | + | ||
120 | + | func aa (T,V) = ((("art_export_cid_" + V) + "_") + T) | |
121 | + | ||
122 | + | ||
123 | + | func ab (T,V) = ((("art_maxmint_" + V) + "_") + T) | |
124 | + | ||
125 | + | ||
126 | + | func ac (T,V) = ((("art_signid_" + V) + "_") + T) | |
127 | + | ||
128 | + | ||
129 | + | func ad (T,V) = ((("art_issued_" + V) + "_") + T) | |
130 | + | ||
131 | + | ||
132 | + | func ae (T,V) = ((("art_onsale_" + V) + "_") + T) | |
133 | + | ||
134 | + | ||
135 | + | func af (T,V) = ((("art_licence_hash_" + V) + "_") + T) | |
136 | + | ||
137 | + | ||
138 | + | func ag (T,V) = ((("art_licence_cid_" + V) + "_") + T) | |
139 | + | ||
140 | + | ||
141 | + | func ah (T,V) = ((("art_tags_" + V) + "_") + T) | |
142 | + | ||
143 | + | ||
144 | + | func ai (T,V) = ((("art_type_" + V) + "_") + T) | |
145 | + | ||
146 | + | ||
147 | + | func aj (T,V) = ((("art_note_" + V) + "_") + T) | |
148 | + | ||
149 | + | ||
150 | + | func ak (T,V) = ((("art_crawler_cid_" + V) + "_") + T) | |
151 | + | ||
152 | + | ||
153 | + | func al (T,V) = ((("art_royalties_" + V) + "_") + T) | |
154 | + | ||
155 | + | ||
156 | + | func am (T,V) = ((("art_price_" + V) + "_") + T) | |
157 | + | ||
158 | + | ||
159 | + | func an (T,V) = ((("art_endsale_" + V) + "_") + T) | |
160 | + | ||
161 | + | ||
162 | + | func ao (T,V) = ((("art_assetAccepted_" + V) + "_") + T) | |
163 | + | ||
164 | + | ||
165 | + | func ap (T,V) = ((("art_flag_" + V) + "_") + T) | |
166 | + | ||
167 | + | ||
168 | + | func aq (ar) = ("artist_agent_" + ar) | |
169 | + | ||
170 | + | ||
171 | + | func as (ar) = ("artist_agent_primary_" + ar) | |
172 | + | ||
173 | + | ||
174 | + | func at (ar) = ("artist_public_agent_" + ar) | |
175 | + | ||
176 | + | ||
177 | + | func au (ar) = ("artist_public_agent_primary_" + ar) | |
178 | + | ||
179 | + | ||
180 | + | func av (T,aw) = ((("get_hashbytxidaddr_" + aw) + "_") + T) | |
181 | + | ||
182 | + | ||
183 | + | func ax (ay) = ("get_owner_by_hash_" + ay) | |
184 | + | ||
185 | + | ||
186 | + | func az (T,aA) = ((("get_artidbysignid_" + aA) + "_") + T) | |
187 | + | ||
188 | + | ||
189 | + | func aB (aC,aD,aE) = if (!(O(aC))) | |
190 | + | then throw("Wrong Display CID") | |
191 | + | else if (!(O(aD))) | |
192 | + | then throw("Wrong Export CID") | |
193 | + | else if (if ((aE != "")) | |
194 | + | then !(O(aE)) | |
195 | + | else false) | |
196 | + | then throw("Wrong Licence CID") | |
197 | + | else true | |
198 | + | ||
199 | + | ||
200 | + | func aF (aG,aH) = if (!(Q(aG))) | |
201 | + | then throw("Export Hash 64 char. max") | |
202 | + | else if (!(Q(aH))) | |
203 | + | then throw("Licence Hash 64 char. max") | |
204 | + | else true | |
205 | + | ||
206 | + | ||
207 | + | func aI (aJ,aK) = if ((size(aJ) == 0)) | |
208 | + | then throw("Field cannot be is empty") | |
209 | + | else if ((size(aJ) > aK)) | |
210 | + | then throw((aJ + " is too long")) | |
211 | + | else true | |
212 | + | ||
213 | + | ||
214 | + | func aL (T) = { | |
215 | + | let aM = valueOrElse(getString(h, S(T)), K) | |
216 | + | if (if ((aM == K)) | |
217 | + | then true | |
218 | + | else (aM == L)) | |
219 | + | then "Register this account first with \"Account\" tab" | |
220 | + | else if ((aM == I)) | |
221 | + | then "Account suspended" | |
222 | + | else if ((aM == J)) | |
223 | + | then "Account removed" | |
224 | + | else "" | |
225 | + | } | |
226 | + | ||
227 | + | ||
228 | + | func aN (aE,aH) = { | |
229 | + | let P = if ((size(aE) == 0)) | |
230 | + | then E | |
231 | + | else aE | |
232 | + | let R = if ((size(aH) == 0)) | |
233 | + | then F | |
234 | + | else aH | |
235 | + | $Tuple2(P, R) | |
236 | + | } | |
237 | + | ||
238 | + | ||
239 | + | func aO (T,aC,aD,aP,aG,aQ,aR,aS,aT,aU) = { | |
240 | + | let aV = aL(T) | |
241 | + | if ((aV != "")) | |
242 | + | then throw(aV) | |
243 | + | else if ((size(aC) == 0)) | |
244 | + | then throw("Display CID cannot be empty") | |
245 | + | else if (!(aB(aC, aD, aP))) | |
246 | + | then throw("Problem with CID") | |
247 | + | else if (!(aF(aG, aQ))) | |
248 | + | then throw("Problem with Hashes") | |
249 | + | else if (!(aI(aR, 100))) | |
250 | + | then throw("100 Char. max name") | |
251 | + | else if (!(aI(aS, 1000))) | |
252 | + | then throw("1000 Char. max description") | |
253 | + | else if (if ((0 > aU)) | |
254 | + | then true | |
255 | + | else (aU > 1000)) | |
256 | + | then throw("Royalties cannot be less than 0% or higher than 10%") | |
257 | + | else if ((size(split(aT, ",")) > 5)) | |
258 | + | then throw("5 tags max.") | |
259 | + | else "" | |
260 | + | } | |
261 | + | ||
262 | + | ||
263 | + | func aW (aX) = if ((size(aX.payments) == 0)) | |
264 | + | then throw("No payment attached") | |
265 | + | else { | |
266 | + | let aY = value(aX.payments[0]) | |
267 | + | let aZ = value(aY.amount) | |
268 | + | $Tuple2(aY, aZ) | |
269 | + | } | |
270 | + | ||
271 | + | ||
272 | + | func ba (aX) = { | |
273 | + | let bb = aW(aX) | |
274 | + | let aY = bb._1 | |
275 | + | let aZ = bb._2 | |
276 | + | let bc = if (if (isDefined(aY.assetId)) | |
277 | + | then (aY.assetId == r) | |
278 | + | else false) | |
279 | + | then aY.assetId | |
280 | + | else throw("Only SIGN token accepted as transaction fee") | |
281 | + | if ((aZ != M)) | |
282 | + | then throw(("Payment amount should be " + toString(M))) | |
283 | + | else $Tuple2(aZ, bc) | |
284 | + | } | |
285 | + | ||
286 | + | ||
287 | + | func bd (be,V) = { | |
288 | + | let bf = getInteger(this, ad(be, V)) | |
289 | + | if ($isInstanceOf(bf, "Int")) | |
73 | 290 | then { | |
74 | - | let | |
75 | - | if ( | |
291 | + | let bg = bf | |
292 | + | if ((bg != 0)) | |
76 | 293 | then true | |
77 | 294 | else false | |
78 | 295 | } | |
80 | 297 | } | |
81 | 298 | ||
82 | 299 | ||
83 | - | func K (L) = if (contains(L, "/")) | |
84 | - | then if (if ((76 > size(L))) | |
85 | - | then (size(split(L, "/")[0]) == 59) | |
300 | + | func bh (aX,bi,bj) = { | |
301 | + | let bk = aW(aX) | |
302 | + | let aY = bk._1 | |
303 | + | let aZ = bk._2 | |
304 | + | let bc = if (!(isDefined(aY.assetId))) | |
305 | + | then unit | |
306 | + | else if (if ((size(bi) > 0)) | |
307 | + | then (toBase58String(value(aY.assetId)) == bi) | |
308 | + | else false) | |
309 | + | then aY.assetId | |
310 | + | else throw("Wrong asset id") | |
311 | + | if (if ((bc == unit)) | |
312 | + | then (bi != "") | |
86 | 313 | else false) | |
87 | - | then (16 > size(split(L, "/")[1])) | |
88 | - | else false | |
89 | - | else false | |
90 | - | ||
91 | - | ||
92 | - | func M (N) = (size(N) == 64) | |
93 | - | ||
94 | - | ||
95 | - | func O (P) = ("user_status_" + P) | |
96 | - | ||
97 | - | ||
98 | - | func Q (P,R) = ((("art_date_" + R) + "_") + P) | |
99 | - | ||
100 | - | ||
101 | - | func S (P,R) = ((("art_name_" + R) + "_") + P) | |
102 | - | ||
103 | - | ||
104 | - | func T (P,R) = ((("art_desc_" + R) + "_") + P) | |
105 | - | ||
106 | - | ||
107 | - | func U (P,R) = ((("art_display_cid_" + R) + "_") + P) | |
108 | - | ||
109 | - | ||
110 | - | func V (P,R) = ((("art_export_hash_" + R) + "_") + P) | |
111 | - | ||
112 | - | ||
113 | - | func W (P,R) = ((("art_export_cid_" + R) + "_") + P) | |
114 | - | ||
115 | - | ||
116 | - | func X (P,R) = ((("art_maxmint_" + R) + "_") + P) | |
117 | - | ||
118 | - | ||
119 | - | func Y (P,R) = ((("art_signid_" + R) + "_") + P) | |
120 | - | ||
121 | - | ||
122 | - | func Z (P,R) = ((("art_issued_" + R) + "_") + P) | |
123 | - | ||
124 | - | ||
125 | - | func aa (P,R) = ((("art_onsale_" + R) + "_") + P) | |
126 | - | ||
127 | - | ||
128 | - | func ab (P,R) = ((("art_licence_hash_" + R) + "_") + P) | |
129 | - | ||
130 | - | ||
131 | - | func ac (P,R) = ((("art_licence_cid_" + R) + "_") + P) | |
132 | - | ||
133 | - | ||
134 | - | func ad (P,R) = ((("art_tags_" + R) + "_") + P) | |
135 | - | ||
136 | - | ||
137 | - | func ae (P,R) = ((("art_type_" + R) + "_") + P) | |
138 | - | ||
139 | - | ||
140 | - | func af (P,R) = ((("art_note_" + R) + "_") + P) | |
141 | - | ||
142 | - | ||
143 | - | func ag (P,R) = ((("art_crawler_cid_" + R) + "_") + P) | |
144 | - | ||
145 | - | ||
146 | - | func ah (P,R) = ((("art_royalties_" + R) + "_") + P) | |
147 | - | ||
148 | - | ||
149 | - | func ai (P,R) = ((("art_price_" + R) + "_") + P) | |
150 | - | ||
151 | - | ||
152 | - | func aj (P,R) = ((("art_endsale_" + R) + "_") + P) | |
153 | - | ||
154 | - | ||
155 | - | func ak (P,R) = ((("art_assetAccepted_" + R) + "_") + P) | |
156 | - | ||
157 | - | ||
158 | - | func al (P,R) = ((("art_flag_" + R) + "_") + P) | |
159 | - | ||
160 | - | ||
161 | - | func am (an) = ("artist_agent_" + an) | |
162 | - | ||
163 | - | ||
164 | - | func ao (an) = ("artist_agent_primary_" + an) | |
165 | - | ||
166 | - | ||
167 | - | func ap (an) = ("artist_public_agent_" + an) | |
168 | - | ||
169 | - | ||
170 | - | func aq (an) = ("artist_public_agent_primary_" + an) | |
171 | - | ||
172 | - | ||
173 | - | func ar (P,as) = ((("get_hashbytxidaddr_" + as) + "_") + P) | |
174 | - | ||
175 | - | ||
176 | - | func at (H) = ("get_owner_by_hash_" + H) | |
177 | - | ||
178 | - | ||
179 | - | func au (P,av) = ((("get_artidbysignid_" + av) + "_") + P) | |
180 | - | ||
181 | - | ||
182 | - | func aw (H,P) = ("get_txid_by_hash_owner_" + toBase58String(sha256_16Kb(toBytes((H + P))))) | |
183 | - | ||
184 | - | ||
185 | - | func ax (ay,az,aA) = if (!(K(ay))) | |
186 | - | then throw("Wrong Display CID") | |
187 | - | else if (!(K(az))) | |
188 | - | then throw("Wrong Export CID") | |
189 | - | else if (if ((aA != "")) | |
190 | - | then !(K(aA)) | |
191 | - | else false) | |
192 | - | then throw("Wrong Licence CID") | |
193 | - | else true | |
194 | - | ||
195 | - | ||
196 | - | func aB (aC,aD) = if (!(M(aC))) | |
197 | - | then throw("Export Hash 64 char. max") | |
198 | - | else if (!(M(aD))) | |
199 | - | then throw("Licence Hash 64 char. max") | |
200 | - | else true | |
201 | - | ||
202 | - | ||
203 | - | func aE (aF,aG) = if ((size(aF) == 0)) | |
204 | - | then throw("Field cannot be is empty") | |
205 | - | else if ((size(aF) > aG)) | |
206 | - | then throw((aF + " is too long")) | |
207 | - | else true | |
208 | - | ||
209 | - | ||
210 | - | func aH (P) = { | |
211 | - | let aI = valueOrElse(getString(h, O(P)), A) | |
212 | - | if (if ((aI == A)) | |
213 | - | then true | |
214 | - | else (aI == B)) | |
215 | - | then "Register this account first with \"Account\" tab" | |
216 | - | else if ((aI == y)) | |
217 | - | then "Account suspended" | |
218 | - | else if ((aI == z)) | |
219 | - | then "Account removed" | |
220 | - | else "" | |
314 | + | then throw("Wrong asset id") | |
315 | + | else if ((bj != aZ)) | |
316 | + | then throw("Payment don't match") | |
317 | + | else $Tuple2(aZ, bc) | |
221 | 318 | } | |
222 | 319 | ||
223 | 320 | ||
224 | - | func aJ (aA,aD) = { | |
225 | - | let L = if ((size(aA) == 0)) | |
226 | - | then u | |
227 | - | else aA | |
228 | - | let N = if ((size(aD) == 0)) | |
229 | - | then v | |
230 | - | else aD | |
231 | - | $Tuple2(L, N) | |
232 | - | } | |
233 | - | ||
234 | - | ||
235 | - | func aK (P,ay,az,aL,aC,aM,aN,aO,aP,aQ) = { | |
236 | - | let aR = aH(P) | |
237 | - | if ((aR != "")) | |
238 | - | then throw(aR) | |
239 | - | else if ((size(ay) == 0)) | |
240 | - | then throw("Display CID cannot be empty") | |
241 | - | else if (!(ax(ay, az, aL))) | |
242 | - | then throw("Problem with CID") | |
243 | - | else if (!(aB(aC, aM))) | |
244 | - | then throw("Problem with Hashes") | |
245 | - | else if (!(aE(aN, 100))) | |
246 | - | then throw("100 Char. max name") | |
247 | - | else if (!(aE(aO, 1000))) | |
248 | - | then throw("1000 Char. max description") | |
249 | - | else if (if ((0 > aQ)) | |
250 | - | then true | |
251 | - | else (aQ > 1000)) | |
252 | - | then throw("Royalties cannot be less than 0% or higher than 10%") | |
253 | - | else if ((size(split(aP, ",")) > 5)) | |
254 | - | then throw("5 tags max.") | |
255 | - | else "" | |
256 | - | } | |
257 | - | ||
258 | - | ||
259 | - | func aS (aT) = if ((size(aT.payments) == 0)) | |
260 | - | then throw("No payment attached") | |
261 | - | else { | |
262 | - | let aU = value(aT.payments[0]) | |
263 | - | let aV = value(aU.amount) | |
264 | - | $Tuple2(aU, aV) | |
265 | - | } | |
266 | - | ||
267 | - | ||
268 | - | func aW (aT) = { | |
269 | - | let aX = aS(aT) | |
270 | - | let aU = aX._1 | |
271 | - | let aV = aX._2 | |
272 | - | let aY = if (if (isDefined(aU.assetId)) | |
273 | - | then (aU.assetId == j) | |
274 | - | else false) | |
275 | - | then aU.assetId | |
276 | - | else throw("Only SIGN token accepted as transaction fee") | |
277 | - | if ((aV != C)) | |
278 | - | then throw(("Payment amount should be " + toString(C))) | |
279 | - | else $Tuple2(aV, aY) | |
280 | - | } | |
281 | - | ||
282 | - | ||
283 | - | func aZ (ba,R) = { | |
284 | - | let I = getInteger(this, Z(ba, R)) | |
285 | - | if ($isInstanceOf(I, "Int")) | |
286 | - | then { | |
287 | - | let bb = I | |
288 | - | if ((bb != 0)) | |
289 | - | then true | |
290 | - | else false | |
291 | - | } | |
292 | - | else false | |
293 | - | } | |
294 | - | ||
295 | - | ||
296 | - | func bc (aT,bd,be) = { | |
297 | - | let bf = aS(aT) | |
298 | - | let aU = bf._1 | |
299 | - | let aV = bf._2 | |
300 | - | let aY = if (!(isDefined(aU.assetId))) | |
301 | - | then unit | |
302 | - | else if (if ((size(bd) > 0)) | |
303 | - | then (toBase58String(value(aU.assetId)) == bd) | |
304 | - | else false) | |
305 | - | then aU.assetId | |
306 | - | else throw("Wrong asset id") | |
307 | - | if (if ((aY == unit)) | |
308 | - | then (bd != "") | |
309 | - | else false) | |
310 | - | then throw("Wrong asset id") | |
311 | - | else if ((be != aV)) | |
312 | - | then throw("Payment don't match") | |
313 | - | else $Tuple2(aV, aY) | |
314 | - | } | |
315 | - | ||
316 | - | ||
317 | - | func bg (aY) = if (if (if (if (if (if ((aY != toBase58String(j))) | |
318 | - | then (aY != toBase58String(n)) | |
319 | - | else false) | |
320 | - | then (aY != "WAVES") | |
321 | - | else false) | |
322 | - | then (aY != toBase58String(k)) | |
323 | - | else false) | |
324 | - | then (aY != toBase58String(l)) | |
325 | - | else false) | |
326 | - | then (aY != toBase58String(m)) | |
327 | - | else false) | |
328 | - | then throw("Only SIGN, USDN,USDT or WAVES accepted") | |
321 | + | func bl (bc) = if (!(containsElement(x, bc))) | |
322 | + | then throw("Only $ART, USDT-PP, USDC-PP, EAST, PUZZLE, ETH or WAVES accepted") | |
329 | 323 | else true | |
330 | 324 | ||
331 | 325 | ||
332 | - | func bh (aY,bi) = { | |
333 | - | let bj = if (d) | |
334 | - | then 10 | |
335 | - | else p("waves_min_sell") | |
336 | - | let bk = 1000000 | |
337 | - | let bl = if (d) | |
338 | - | then 1 | |
339 | - | else (C * 2) | |
340 | - | if (if (if (if (if (if (if ((aY == toBase58String(k))) | |
341 | - | then (bk > bi) | |
342 | - | else false) | |
343 | - | then (bi != 0) | |
344 | - | else false) | |
345 | - | then true | |
346 | - | else if (if ((aY == toBase58String(l))) | |
347 | - | then (bk > bi) | |
348 | - | else false) | |
349 | - | then (bi != 0) | |
350 | - | else false) | |
351 | - | then true | |
352 | - | else if (if ((aY == toBase58String(m))) | |
353 | - | then (bk > bi) | |
354 | - | else false) | |
355 | - | then (bi != 0) | |
356 | - | else false) | |
357 | - | then true | |
358 | - | else if (if ((aY == toBase58String(j))) | |
359 | - | then (bl > bi) | |
360 | - | else false) | |
361 | - | then (bi != 0) | |
362 | - | else false) | |
363 | - | then true | |
364 | - | else if (if (if ((aY == toBase58String(n))) | |
365 | - | then true | |
366 | - | else (aY == "WAVES")) | |
367 | - | then (bj > bi) | |
368 | - | else false) | |
369 | - | then (bi != 0) | |
370 | - | else false) | |
371 | - | then throw("Wrong minimum sell price") | |
372 | - | else true | |
373 | - | } | |
326 | + | func bm (bn) = if ((0 >= bn)) | |
327 | + | then throw("Wrong minimum sell price") | |
328 | + | else true | |
374 | 329 | ||
375 | 330 | ||
376 | - | func | |
331 | + | func bo (bc) = if ((bc == "WAVES")) | |
377 | 332 | then unit | |
378 | - | else fromBase58String( | |
333 | + | else fromBase58String(bc) | |
379 | 334 | ||
380 | 335 | ||
381 | - | func | |
382 | - | let | |
383 | - | if (( | |
336 | + | func bp (bq) = { | |
337 | + | let br = b((bq + "_OPEN")) | |
338 | + | if ((br == "")) | |
384 | 339 | then throw("Bid not found") | |
385 | 340 | else { | |
386 | - | let | |
387 | - | let | |
388 | - | let | |
389 | - | if ((0 >= | |
341 | + | let bs = split(br, "_") | |
342 | + | let bt = parseIntValue(bs[1]) | |
343 | + | let bu = bo(bs[0]) | |
344 | + | if ((0 >= bt)) | |
390 | 345 | then throw("Wrong amount") | |
391 | - | else $Tuple2( | |
346 | + | else $Tuple2(bt, bu) | |
392 | 347 | } | |
393 | 348 | } | |
394 | 349 | ||
395 | 350 | ||
396 | - | func | |
397 | - | then throw( | |
351 | + | func bv (aX,bw) = if (!(G)) | |
352 | + | then throw(H) | |
398 | 353 | else { | |
399 | - | let | |
400 | - | then valueOrElse( | |
354 | + | let bx = if ((bw != "")) | |
355 | + | then valueOrElse(B((toString(addressFromPublicKey(fromBase58String(bw))) + "_free_txs")), 0) | |
401 | 356 | else 0 | |
402 | - | let | |
403 | - | then ( | |
357 | + | let T = if (if ((toBase58String(aX.caller.bytes) == toString(this))) | |
358 | + | then (bx > 0) | |
404 | 359 | else false) | |
405 | - | then toString(addressFromPublicKey(fromBase58String( | |
406 | - | else toBase58String( | |
407 | - | let | |
408 | - | then ( | |
360 | + | then toString(addressFromPublicKey(fromBase58String(bw))) | |
361 | + | else toBase58String(aX.caller.bytes) | |
362 | + | let by = if (if ((bw != "")) | |
363 | + | then (bx > 0) | |
409 | 364 | else false) | |
410 | - | then invoke(i, "useFreeTx", [toString(addressFromPublicKey(fromBase58String( | |
365 | + | then invoke(i, "useFreeTx", [toString(addressFromPublicKey(fromBase58String(bw)))], nil) | |
411 | 366 | else unit | |
412 | - | if (( | |
413 | - | then $Tuple4(toBase58String( | |
367 | + | if ((by == by)) | |
368 | + | then $Tuple4(toBase58String(aX.transactionId), T, lastBlock.timestamp, (bx > 0)) | |
414 | 369 | else throw("Strict value is not equal to itself.") | |
415 | 370 | } | |
416 | 371 | ||
417 | 372 | ||
418 | - | func | |
419 | - | then throw( | |
420 | - | else $Tuple3(toBase58String( | |
373 | + | func bz (aX) = if (!(G)) | |
374 | + | then throw(H) | |
375 | + | else $Tuple3(toBase58String(aX.transactionId), toBase58String(aX.caller.bytes), lastBlock.timestamp) | |
421 | 376 | ||
422 | 377 | ||
423 | - | func by (aT,R,bz,bA,bB,bu) = { | |
424 | - | let bC = bt(aT, bu) | |
425 | - | let bD = bC._1 | |
426 | - | let P = bC._2 | |
427 | - | let bE = bC._3 | |
428 | - | let bv = bC._4 | |
429 | - | let bF = if (if (if ((P == bz)) | |
430 | - | then (bB != "") | |
378 | + | func bA (bc) = { | |
379 | + | let bf = bc | |
380 | + | if ($isInstanceOf(bf, "ByteVector")) | |
381 | + | then { | |
382 | + | let bg = bf | |
383 | + | assetBalance(this, bg) | |
384 | + | } | |
385 | + | else wavesBalance(this).available | |
386 | + | } | |
387 | + | ||
388 | + | ||
389 | + | func bB (aX,V,bC,bD,bE,bw) = { | |
390 | + | let bF = bv(aX, bw) | |
391 | + | let bG = bF._1 | |
392 | + | let T = bF._2 | |
393 | + | let bH = bF._3 | |
394 | + | let bx = bF._4 | |
395 | + | let bI = if (if (if ((T == bC)) | |
396 | + | then (bE != "") | |
431 | 397 | else false) | |
432 | - | then ( | |
398 | + | then (bD != "") | |
433 | 399 | else false) | |
434 | 400 | then true | |
435 | 401 | else false | |
436 | - | if (if ( | |
437 | - | then ( | |
402 | + | if (if (bI) | |
403 | + | then (T != bC) | |
438 | 404 | else false) | |
439 | 405 | then throw("You cannot do this action") | |
440 | 406 | else { | |
441 | - | let | |
442 | - | if (if (if (( | |
443 | - | then (height >= | |
407 | + | let bJ = A(an(T, V)) | |
408 | + | if (if (if ((bJ != 0)) | |
409 | + | then (height >= bJ) | |
444 | 410 | else false) | |
445 | - | then !( | |
411 | + | then !(bI) | |
446 | 412 | else false) | |
447 | 413 | then throw("Sale ended.") | |
448 | 414 | else { | |
449 | - | let bH = (P == bz) | |
450 | - | let bI = q("total_nft_issued") | |
451 | - | let F = b(Y(bz, R)) | |
452 | - | let bJ = b(S(bz, R)) | |
453 | - | if ((bJ == "")) | |
415 | + | let bK = (T == bC) | |
416 | + | let bL = A("total_nft_issued") | |
417 | + | let bM = b(W(bC, V)) | |
418 | + | if ((bM == "")) | |
454 | 419 | then throw("Art doesn't exist") | |
455 | 420 | else { | |
456 | - | let | |
457 | - | let | |
458 | - | let | |
459 | - | then ( | |
460 | - | else | |
461 | - | let | |
462 | - | then toBase58String( | |
463 | - | else b( | |
464 | - | let | |
465 | - | if (if (if (!( | |
466 | - | then !( | |
421 | + | let bN = C(ae(bC, V)) | |
422 | + | let bO = A(ad(bC, V)) | |
423 | + | let bj = if (bK) | |
424 | + | then (M * 2) | |
425 | + | else A(am(bC, V)) | |
426 | + | let bi = if (bK) | |
427 | + | then toBase58String(r) | |
428 | + | else b(ao(bC, V)) | |
429 | + | let bP = A(ab(bC, V)) | |
430 | + | if (if (if (!(bI)) | |
431 | + | then !(bK) | |
467 | 432 | else false) | |
468 | - | then if (if ((0 >= | |
433 | + | then if (if ((0 >= bj)) | |
469 | 434 | then true | |
470 | - | else !( | |
435 | + | else !(bN)) | |
471 | 436 | then true | |
472 | - | else (0 >= | |
437 | + | else (0 >= bP) | |
473 | 438 | else false) | |
474 | 439 | then throw("Art not for sale") | |
475 | - | else if (if (if (!( | |
476 | - | then | |
440 | + | else if (if (if (!(bI)) | |
441 | + | then bK | |
477 | 442 | else false) | |
478 | - | then (0 >= | |
443 | + | then (0 >= bP) | |
479 | 444 | else false) | |
480 | 445 | then throw("Max issuable not set") | |
481 | 446 | else { | |
482 | - | let | |
483 | - | if (if ( | |
484 | - | then ( | |
447 | + | let aV = aL(bC) | |
448 | + | if (if (bI) | |
449 | + | then (aV != "") | |
485 | 450 | else false) | |
486 | - | then throw( | |
451 | + | then throw(aV) | |
487 | 452 | else { | |
488 | - | let | |
489 | - | let | |
490 | - | then | |
491 | - | else | |
492 | - | let | |
493 | - | let | |
494 | - | let | |
495 | - | let | |
496 | - | let | |
497 | - | let | |
498 | - | let | |
499 | - | let | |
500 | - | let | |
501 | - | then ( | |
453 | + | let bq = ((((((("bid_" + V) + "_") + bC) + "_") + bE) + "_") + bD) | |
454 | + | let bQ = if (bI) | |
455 | + | then bp(bq) | |
456 | + | else bh(aX, bi, bj) | |
457 | + | let aZ = bQ._1 | |
458 | + | let bc = bQ._2 | |
459 | + | let bR = valueOrElse(getString(h, aq(bC)), g) | |
460 | + | let bS = valueOrElse(getInteger(h, as(bC)), 0) | |
461 | + | let bT = valueOrElse(getString(h, at(bC)), g) | |
462 | + | let bU = valueOrElse(getInteger(h, au(bC)), 0) | |
463 | + | let bV = B(bC) | |
464 | + | let bW = fraction(aZ, D, 100) | |
465 | + | let bX = if (if (if ((bR != g)) | |
466 | + | then (bS > 0) | |
502 | 467 | else false) | |
503 | - | then (height > | |
468 | + | then (height > bV) | |
504 | 469 | else false) | |
505 | - | then fraction( | |
470 | + | then fraction(aZ, bS, 10000) | |
506 | 471 | else 0 | |
507 | - | let | |
508 | - | then ( | |
472 | + | let bY = if (if (if ((bT != g)) | |
473 | + | then (bU > 0) | |
509 | 474 | else false) | |
510 | - | then (height > | |
475 | + | then (height > bV) | |
511 | 476 | else false) | |
512 | - | then fraction( | |
477 | + | then fraction(aZ, bU, 10000) | |
513 | 478 | else 0 | |
514 | - | let | |
515 | - | if (( | |
479 | + | let bZ = (aZ - bW) | |
480 | + | if ((bO == bP)) | |
516 | 481 | then throw("Art sold out") | |
517 | 482 | else { | |
518 | - | let bX = (bL + 1) | |
519 | - | let bY = ((((((((((("Creator: " + bz) + ", | |
520 | - | ArtID: ") + R) + ", | |
521 | - | SignID: ") + F) + ", | |
522 | - | Artwork name: ") + bJ) + ", | |
523 | - | Issue: ") + toString(bX)) + "/") + toString(bM)) | |
524 | - | let bZ = Issue(("SA_" + toString((bI + 1))), bY, 1, 0, false) | |
525 | - | let ca = calculateAssetId(bZ) | |
526 | - | let cb = if (if ((bX == bM)) | |
483 | + | let ca = (bO + 1) | |
484 | + | let cb = ((((((((("Creator: " + bC) + ", | |
485 | + | ArtID: ") + V) + ", | |
486 | + | Artwork name: ") + bM) + ", | |
487 | + | Issue: ") + toString(ca)) + "/") + toString(bP)) | |
488 | + | let cc = Issue(("SA_" + toString((bL + 1))), cb, 1, 0, false) | |
489 | + | let cd = calculateAssetId(cc) | |
490 | + | let ce = if (if ((ca == bP)) | |
527 | 491 | then true | |
528 | - | else !( | |
492 | + | else !(bN)) | |
529 | 493 | then false | |
530 | 494 | else true | |
531 | - | let | |
532 | - | then ( | |
495 | + | let cf = if (if (if ((T == bC)) | |
496 | + | then (bE != "") | |
533 | 497 | else false) | |
534 | - | then ( | |
498 | + | then (bD != "") | |
535 | 499 | else false) | |
536 | - | then addressFromStringValue( | |
537 | - | else | |
538 | - | let | |
500 | + | then addressFromStringValue(bE) | |
501 | + | else aX.caller | |
502 | + | let cg = if (!(isDefined(bc))) | |
539 | 503 | then "WAVES" | |
540 | - | else toBase58String(value( | |
541 | - | let | |
542 | - | let | |
543 | - | let | |
544 | - | let | |
545 | - | let | |
546 | - | then (((((((((( | |
547 | - | else ((((((((((toString( | |
548 | - | let | |
549 | - | let | |
550 | - | then [ScriptTransfer(Address(fromBase58String(g)), ( | |
551 | - | else [ScriptTransfer(Address(fromBase58String(g)), | |
552 | - | let | |
553 | - | then [ScriptTransfer(Address(fromBase58String( | |
554 | - | else [ScriptTransfer(Address(fromBase58String( | |
555 | - | let | |
556 | - | then [ScriptTransfer(Address(fromBase58String( | |
504 | + | else toBase58String(value(bc)) | |
505 | + | let br = b((bq + "_OPEN")) | |
506 | + | let ch = DeleteEntry((bq + "_OPEN")) | |
507 | + | let ci = StringEntry((bq + "_CLOSED"), ((br + "_") + toString(bH))) | |
508 | + | let cj = ((((((("art_sold_" + toString(ca)) + "_of_") + toString(bP)) + "_") + V) + "_") + bC) | |
509 | + | let ck = if (!(bI)) | |
510 | + | then ((((((((((T + "_") + toString(bH)) + "_") + bG) + "_") + toString(bj)) + "_") + bi) + "_") + toBase58String(cd)) | |
511 | + | else ((((((((((toString(cf) + "_") + toString(bH)) + "_") + bG) + "_") + toString(aZ)) + "_") + cg) + "_") + toBase58String(cd)) | |
512 | + | let cl = StringEntry(cj, ck) | |
513 | + | let cm = if ((bX != 0)) | |
514 | + | then [ScriptTransfer(Address(fromBase58String(g)), (bW - bX), bc), ScriptTransfer(Address(fromBase58String(bR)), bX, bc)] | |
515 | + | else [ScriptTransfer(Address(fromBase58String(g)), bW, bc)] | |
516 | + | let cn = if ((bY != 0)) | |
517 | + | then [ScriptTransfer(Address(fromBase58String(bT)), bY, bc), ScriptTransfer(Address(fromBase58String(bC)), (bZ - bY), bc)] | |
518 | + | else [ScriptTransfer(Address(fromBase58String(bC)), bZ, bc)] | |
519 | + | let co = if (bx) | |
520 | + | then [ScriptTransfer(Address(fromBase58String(T)), 0, unit)] | |
557 | 521 | else nil | |
558 | - | let | |
559 | - | if ( | |
560 | - | then [ci, | |
561 | - | else | |
522 | + | let cp = ((([IntegerEntry(ad(bC, V), ca), StringEntry(("nft_" + toBase58String(cd)), cj), IntegerEntry("total_nft_issued", (bL + 1)), IntegerEntry(an(bC, V), 0), BooleanEntry(ae(bC, V), ce), cc, ScriptTransfer(cf, 1, cd)] ++ cm) ++ cn) ++ co) | |
523 | + | if (bI) | |
524 | + | then [cl, ci, ch] :: cp | |
525 | + | else cl :: cp | |
562 | 526 | } | |
563 | 527 | } | |
564 | 528 | } | |
568 | 532 | } | |
569 | 533 | ||
570 | 534 | ||
571 | - | func | |
572 | - | let | |
573 | - | if ($isInstanceOf( | |
535 | + | func cq (cr) = { | |
536 | + | let bf = cr | |
537 | + | if ($isInstanceOf(bf, "String")) | |
574 | 538 | then { | |
575 | - | let | |
576 | - | | |
539 | + | let cs = bf | |
540 | + | cs | |
577 | 541 | } | |
578 | 542 | else throw("Sponsored Public Key String expected") | |
579 | 543 | } | |
580 | 544 | ||
581 | 545 | ||
582 | - | @Callable( | |
583 | - | func setConf (c, | |
584 | - | let | |
585 | - | if (containsElement([ | |
546 | + | @Callable(ct) | |
547 | + | func setConf (c,cu) = { | |
548 | + | let T = toString(ct.caller) | |
549 | + | if (containsElement([y, toString(this)], T)) | |
586 | 550 | then if (contains(c, "conf_")) | |
587 | - | then [StringEntry(c, | |
551 | + | then [StringEntry(c, cu)] | |
588 | 552 | else throw("Entries starting with conf_ only") | |
589 | 553 | else throw("You are not allowed to change this") | |
590 | 554 | } | |
591 | 555 | ||
592 | 556 | ||
593 | 557 | ||
594 | - | @Callable(aT) | |
595 | - | func addArtwork (H,F,aN,aO,aP,cs,ay,aC,az,aD,aA,ct,aQ,bu) = { | |
596 | - | let cu = bt(aT, bu) | |
597 | - | let R = cu._1 | |
598 | - | let P = cu._2 | |
599 | - | let bE = cu._3 | |
600 | - | let bv = cu._4 | |
601 | - | if (!(M(H))) | |
602 | - | then throw("Hash should be 64 characters maximum") | |
558 | + | @Callable(aX) | |
559 | + | func addArtwork (aR,aS,aT,cv,aC,aG,aD,aH,aE,cw,aU,bw) = { | |
560 | + | let cx = bv(aX, bw) | |
561 | + | let V = cx._1 | |
562 | + | let T = cx._2 | |
563 | + | let bH = cx._3 | |
564 | + | let bx = cx._4 | |
565 | + | let cy = aN(aE, aH) | |
566 | + | let aP = cy._1 | |
567 | + | let aQ = cy._2 | |
568 | + | let cz = aO(T, aC, aD, aP, aG, aQ, aR, aS, aT, aU) | |
569 | + | if ((cz != "")) | |
570 | + | then throw("Something went wrong!") | |
603 | 571 | else { | |
604 | - | let cv = aJ(aA, aD) | |
605 | - | let aL = cv._1 | |
606 | - | let aM = cv._2 | |
607 | - | let cw = aK(P, ay, az, aL, aC, aM, aN, aO, aP, aQ) | |
608 | - | if ((cw != "")) | |
609 | - | then throw("Something went wrong!") | |
572 | + | let cA = (B((T + "_free_drops")) > 0) | |
573 | + | let cB = if (cA) | |
574 | + | then $Tuple2(0, r) | |
575 | + | else ba(aX) | |
576 | + | let aZ = cB._1 | |
577 | + | let bc = cB._2 | |
578 | + | if (!(isDefined(aZ))) | |
579 | + | then throw("Something went wrong") | |
610 | 580 | else { | |
611 | - | let cx = (r((P + "_free_drops")) > 0) | |
612 | - | let cy = if (cx) | |
613 | - | then $Tuple2(0, F) | |
614 | - | else aW(aT) | |
615 | - | let aV = cy._1 | |
616 | - | let aY = cy._2 | |
617 | - | if (!(isDefined(aV))) | |
618 | - | then throw("Something went wrong") | |
619 | - | else { | |
620 | - | let cz = b(aw(H, P)) | |
621 | - | if ((cz != "")) | |
622 | - | then throw("You already added it") | |
623 | - | else { | |
624 | - | let cA = b(at(H)) | |
625 | - | if ((cA != "")) | |
626 | - | then throw("Hash already registered") | |
627 | - | else { | |
628 | - | let cB = E(F, P, H) | |
629 | - | if (!(cB)) | |
630 | - | then throw("Sign Certificate not found for this address.") | |
631 | - | else { | |
632 | - | let cC = if (cx) | |
633 | - | then invoke(i, "useFreeDrop", [P], nil) | |
634 | - | else unit | |
635 | - | if ((cC == cC)) | |
636 | - | then { | |
637 | - | let cl = if (bv) | |
638 | - | then [ScriptTransfer(Address(fromBase58String(P)), 0, unit)] | |
639 | - | else nil | |
640 | - | ([StringEntry(at(H), P), StringEntry(aw(H, P), R), IntegerEntry(Q(P, R), bE), StringEntry(S(P, R), aN), StringEntry(T(P, R), aO), StringEntry(U(P, R), ay), StringEntry(W(P, R), az), StringEntry(V(P, R), aC), StringEntry(ab(P, R), aM), StringEntry(ac(P, R), aL), StringEntry(ae(P, R), cs), StringEntry(ad(P, R), aP), IntegerEntry(X(P, R), 0), StringEntry(Y(P, R), F), IntegerEntry(Z(P, R), 0), BooleanEntry(aa(P, R), false), StringEntry(au(P, F), R), StringEntry(ar(P, R), H), StringEntry(ag(P, R), ct), IntegerEntry(ah(P, R), aQ), ScriptTransfer(Address(fromBase58String(g)), aV, j)] ++ cl) | |
641 | - | } | |
642 | - | else throw("Strict value is not equal to itself.") | |
643 | - | } | |
644 | - | } | |
645 | - | } | |
581 | + | let cC = if (cA) | |
582 | + | then invoke(i, "useFreeDrop", [T], nil) | |
583 | + | else unit | |
584 | + | if ((cC == cC)) | |
585 | + | then { | |
586 | + | let co = if (bx) | |
587 | + | then [ScriptTransfer(Address(fromBase58String(T)), 0, unit)] | |
588 | + | else nil | |
589 | + | ([IntegerEntry(U(T, V), bH), StringEntry(W(T, V), aR), StringEntry(X(T, V), aS), StringEntry(Y(T, V), aC), StringEntry(aa(T, V), aD), StringEntry(Z(T, V), aG), StringEntry(af(T, V), aQ), StringEntry(ag(T, V), aP), StringEntry(ai(T, V), cv), StringEntry(ah(T, V), aT), IntegerEntry(ab(T, V), 0), IntegerEntry(ad(T, V), 0), BooleanEntry(ae(T, V), false), StringEntry(ak(T, V), cw), IntegerEntry(al(T, V), aU), ScriptTransfer(Address(fromBase58String(g)), aZ, r)] ++ co) | |
646 | 590 | } | |
591 | + | else throw("Strict value is not equal to itself.") | |
647 | 592 | } | |
648 | 593 | } | |
649 | 594 | } | |
650 | 595 | ||
651 | 596 | ||
652 | 597 | ||
653 | - | @Callable( | |
654 | - | func updateArtwork ( | |
655 | - | then throw( | |
598 | + | @Callable(aX) | |
599 | + | func updateArtwork (aw,aR,aS,aT,cv,aC,aG,aD,aH,aE,cw,aU,bw) = if (!(G)) | |
600 | + | then throw(H) | |
656 | 601 | else { | |
657 | - | let cD = | |
658 | - | let | |
659 | - | let | |
660 | - | let | |
661 | - | let | |
662 | - | let cE = | |
663 | - | let | |
664 | - | let | |
665 | - | let | |
666 | - | if (( | |
602 | + | let cD = bv(aX, bw) | |
603 | + | let bG = cD._1 | |
604 | + | let T = cD._2 | |
605 | + | let bH = cD._3 | |
606 | + | let bx = cD._4 | |
607 | + | let cE = aN(aE, aH) | |
608 | + | let aP = cE._1 | |
609 | + | let aQ = cE._2 | |
610 | + | let cz = aO(T, aC, aD, aP, aG, aQ, aR, aS, aT, aU) | |
611 | + | if ((cz != "")) | |
667 | 612 | then throw("Something went wrong!") | |
668 | 613 | else { | |
669 | - | let | |
670 | - | if (( | |
614 | + | let cF = b(W(T, aw)) | |
615 | + | if ((cF == "")) | |
671 | 616 | then throw("Entry not found") | |
672 | 617 | else { | |
673 | - | let | |
674 | - | if (( | |
618 | + | let cG = b(ap(T, aw)) | |
619 | + | if ((cG == "ILLEGAL")) | |
675 | 620 | then throw("Cannot update ILLEGAL artwork") | |
676 | - | else if (!( | |
621 | + | else if (!(bd(T, aw))) | |
677 | 622 | then { | |
678 | - | let | |
679 | - | then [ScriptTransfer(Address(fromBase58String( | |
623 | + | let co = if (bx) | |
624 | + | then [ScriptTransfer(Address(fromBase58String(T)), 0, unit)] | |
680 | 625 | else nil | |
681 | - | ([StringEntry( | |
626 | + | ([StringEntry(W(T, aw), aR), StringEntry(X(T, aw), aS), StringEntry(Y(T, aw), aC), StringEntry(aa(T, aw), aD), StringEntry(Z(T, aw), aG), StringEntry(ag(T, aw), aP), StringEntry(af(T, aw), aQ), StringEntry(ah(T, aw), aT), StringEntry(ai(T, aw), cv), StringEntry(ak(T, aw), cw), IntegerEntry(al(T, aw), aU)] ++ co) | |
682 | 627 | } | |
683 | 628 | else throw("Already minted") | |
684 | 629 | } | |
687 | 632 | ||
688 | 633 | ||
689 | 634 | ||
690 | - | @Callable( | |
691 | - | func flagArtwork ( | |
692 | - | let | |
693 | - | let | |
694 | - | let | |
695 | - | if (containsElement([ | |
696 | - | then if (containsElement(["CONSENT", "", "CHANGE_REQUIRED", "FLAGGED", "ILLEGAL"], | |
697 | - | then [StringEntry( | |
698 | - | else throw(("Unknow status " + | |
635 | + | @Callable(aX) | |
636 | + | func flagArtwork (V,cH,cG,cI) = { | |
637 | + | let cJ = bz(aX) | |
638 | + | let bG = cJ._1 | |
639 | + | let T = cJ._2 | |
640 | + | if (containsElement([y, toString(this)], T)) | |
641 | + | then if (containsElement(["CONSENT", "", "CHANGE_REQUIRED", "FLAGGED", "ILLEGAL"], cG)) | |
642 | + | then [StringEntry(ap(cH, V), cG), StringEntry(aj(cH, V), cI)] | |
643 | + | else throw(("Unknow status " + cG)) | |
699 | 644 | else throw("You are not allowed") | |
700 | 645 | } | |
701 | 646 | ||
702 | 647 | ||
703 | 648 | ||
704 | - | @Callable( | |
705 | - | func deleteArtwork ( | |
706 | - | let | |
707 | - | let | |
708 | - | let | |
709 | - | let | |
710 | - | then | |
711 | - | else | |
712 | - | let | |
713 | - | if (( | |
649 | + | @Callable(aX) | |
650 | + | func deleteArtwork (V,cH) = { | |
651 | + | let cK = bz(aX) | |
652 | + | let bG = cK._1 | |
653 | + | let T = cK._2 | |
654 | + | let be = if (containsElement([y, toString(this)], T)) | |
655 | + | then cH | |
656 | + | else T | |
657 | + | let cF = valueOrErrorMessage(b(W(be, V)), "No art matching for this address") | |
658 | + | if ((cF == "")) | |
714 | 659 | then throw("No art matching for this address") | |
715 | 660 | else { | |
716 | - | let H = b(ar(ba, R)) | |
717 | - | if ((H == "")) | |
718 | - | then throw("No art hash matching for this address") | |
719 | - | else { | |
720 | - | let F = b(Y(ba, R)) | |
721 | - | if ((F == "")) | |
722 | - | then throw("No SIGN ID matching") | |
723 | - | else { | |
724 | - | let cK = [DeleteEntry(Q(ba, R)), DeleteEntry(S(ba, R)), DeleteEntry(T(ba, R)), DeleteEntry(U(ba, R)), DeleteEntry(W(ba, R)), DeleteEntry(V(ba, R)), DeleteEntry(ab(ba, R)), DeleteEntry(ac(ba, R)), DeleteEntry(ae(ba, R)), DeleteEntry(ad(ba, R)), DeleteEntry(X(ba, R)), DeleteEntry(Y(ba, R)), DeleteEntry(Z(ba, R)), DeleteEntry(aa(ba, R)), DeleteEntry(al(ba, R)), DeleteEntry(ai(ba, R)), DeleteEntry(ak(ba, R)), DeleteEntry(at(H)), DeleteEntry(au(ba, F)), DeleteEntry(aw(H, ba)), DeleteEntry(aj(ba, R)), DeleteEntry(af(ba, R)), DeleteEntry(ag(ba, R)), DeleteEntry(ah(ba, R))] | |
725 | - | if (!(aZ(ba, R))) | |
726 | - | then if (!(w)) | |
727 | - | then throw(x) | |
728 | - | else cK | |
729 | - | else if (containsElement([o, toString(this)], P)) | |
730 | - | then cK | |
731 | - | else throw("Art already minted, you cannot delete it") | |
732 | - | } | |
733 | - | } | |
661 | + | let ay = b(av(be, V)) | |
662 | + | let cL = if ((ay == "")) | |
663 | + | then b(ac(be, V)) | |
664 | + | else "" | |
665 | + | let cM = if ((cL == "")) | |
666 | + | then nil | |
667 | + | else [DeleteEntry(az(be, cL))] | |
668 | + | let cN = ([DeleteEntry(U(be, V)), DeleteEntry(W(be, V)), DeleteEntry(X(be, V)), DeleteEntry(Y(be, V)), DeleteEntry(aa(be, V)), DeleteEntry(Z(be, V)), DeleteEntry(af(be, V)), DeleteEntry(ag(be, V)), DeleteEntry(ai(be, V)), DeleteEntry(ah(be, V)), DeleteEntry(ab(be, V)), DeleteEntry(ac(be, V)), DeleteEntry(ad(be, V)), DeleteEntry(ae(be, V)), DeleteEntry(ap(be, V)), DeleteEntry(am(be, V)), DeleteEntry(ao(be, V)), DeleteEntry(ax(ay)), DeleteEntry(an(be, V)), DeleteEntry(aj(be, V)), DeleteEntry(ak(be, V)), DeleteEntry(al(be, V))] ++ cM) | |
669 | + | if (!(bd(be, V))) | |
670 | + | then if (!(G)) | |
671 | + | then throw(H) | |
672 | + | else cN | |
673 | + | else if (containsElement([y, toString(this)], T)) | |
674 | + | then cN | |
675 | + | else throw("Art already minted, you cannot delete it") | |
734 | 676 | } | |
735 | 677 | } | |
736 | 678 | ||
737 | 679 | ||
738 | 680 | ||
739 | - | @Callable( | |
740 | - | func sellArtwork ( | |
741 | - | let | |
742 | - | let | |
743 | - | let | |
744 | - | let | |
745 | - | let | |
746 | - | let | |
747 | - | if (( | |
681 | + | @Callable(aX) | |
682 | + | func sellArtwork (V,bn,cO,bc,bJ,bw) = { | |
683 | + | let cP = bv(aX, bw) | |
684 | + | let bG = cP._1 | |
685 | + | let T = cP._2 | |
686 | + | let bH = cP._3 | |
687 | + | let bx = cP._4 | |
688 | + | let bM = b(W(T, V)) | |
689 | + | if ((bM == "")) | |
748 | 690 | then throw("This art doesn't match your account") | |
749 | 691 | else { | |
750 | - | let | |
751 | - | if (containsElement(["CHANGE_REQUIRED", "FLAGGED", "ILLEGAL"], | |
692 | + | let cG = b(ap(T, V)) | |
693 | + | if (containsElement(["CHANGE_REQUIRED", "FLAGGED", "ILLEGAL"], cG)) | |
752 | 694 | then throw("Flagged artwork") | |
753 | 695 | else { | |
754 | - | let | |
755 | - | if ((0 > | |
696 | + | let cQ = A(("current_bidamount_" + V)) | |
697 | + | if ((0 > bJ)) | |
756 | 698 | then throw("Negative end") | |
757 | - | else if (if (( | |
758 | - | then if (( | |
699 | + | else if (if ((bJ > 0)) | |
700 | + | then if ((cO != 1)) | |
759 | 701 | then true | |
760 | - | else ( | |
702 | + | else (bn != 0) | |
761 | 703 | else false) | |
762 | 704 | then throw("Timed offer only allowed for unique edition and offer only") | |
763 | 705 | else { | |
764 | - | let | |
706 | + | let cR = if ((bJ == 0)) | |
765 | 707 | then 0 | |
766 | 708 | else height | |
767 | - | if (!( | |
709 | + | if (!(bl(bc))) | |
768 | 710 | then throw("Something went wrong!") | |
769 | - | else if (!( | |
711 | + | else if (!(bm(bn))) | |
770 | 712 | then throw("Something went wrong!") | |
771 | 713 | else { | |
772 | - | let | |
773 | - | if (( | |
774 | - | then throw( | |
714 | + | let aV = aL(T) | |
715 | + | if ((aV != "")) | |
716 | + | then throw(aV) | |
775 | 717 | else { | |
776 | - | let | |
777 | - | let | |
778 | - | if (( | |
718 | + | let bO = A(ad(T, V)) | |
719 | + | let bP = A(ab(T, V)) | |
720 | + | if ((cO > 100)) | |
779 | 721 | then throw("100 editions max per artwork") | |
780 | - | else if (if (( | |
781 | - | then ( | |
722 | + | else if (if ((bO != 0)) | |
723 | + | then (bO == bP) | |
782 | 724 | else false) | |
783 | 725 | then throw("Max edition reached.") | |
784 | - | else if (if (( | |
785 | - | then ( | |
726 | + | else if (if ((bO > 0)) | |
727 | + | then (bP != cO) | |
786 | 728 | else false) | |
787 | 729 | then throw("Cannot change maximum issuable anymore") | |
788 | - | else if (if (( | |
789 | - | then ( | |
730 | + | else if (if ((cQ > 0)) | |
731 | + | then (bP != cO) | |
790 | 732 | else false) | |
791 | 733 | then throw("Cannot change maximum issuable with active orders") | |
792 | 734 | else { | |
793 | - | let | |
794 | - | then ( | |
735 | + | let ce = if (if ((bn > 0)) | |
736 | + | then (cO > 0) | |
795 | 737 | else false) | |
796 | 738 | then true | |
797 | 739 | else false | |
798 | - | let | |
799 | - | then [ScriptTransfer(Address(fromBase58String( | |
740 | + | let co = if (bx) | |
741 | + | then [ScriptTransfer(Address(fromBase58String(T)), 0, unit)] | |
800 | 742 | else nil | |
801 | - | ([BooleanEntry( | |
743 | + | ([BooleanEntry(ae(T, V), ce), IntegerEntry(am(T, V), bn), IntegerEntry(ab(T, V), cO), StringEntry(ao(T, V), bc), IntegerEntry(an(T, V), (cR + bJ))] ++ co) | |
802 | 744 | } | |
803 | 745 | } | |
804 | 746 | } | |
809 | 751 | ||
810 | 752 | ||
811 | 753 | ||
812 | - | @Callable( | |
813 | - | func buyArtwork ( | |
754 | + | @Callable(aX) | |
755 | + | func buyArtwork (V,bC) = bB(aX, V, bC, "", "", "") | |
814 | 756 | ||
815 | 757 | ||
816 | 758 | ||
817 | - | @Callable( | |
818 | - | func setBid ( | |
819 | - | let | |
820 | - | let | |
821 | - | let | |
822 | - | let | |
823 | - | let | |
824 | - | let | |
825 | - | let | |
826 | - | let | |
759 | + | @Callable(aX) | |
760 | + | func setBid (V,bC) = { | |
761 | + | let cS = bz(aX) | |
762 | + | let bG = cS._1 | |
763 | + | let T = cS._2 | |
764 | + | let bH = cS._3 | |
765 | + | let cT = aW(aX) | |
766 | + | let aY = cT._1 | |
767 | + | let aZ = cT._2 | |
768 | + | let bc = if (!(isDefined(aY.assetId))) | |
827 | 769 | then "WAVES" | |
828 | - | else toBase58String(value( | |
829 | - | let | |
830 | - | if (if (( | |
831 | - | then (height >= | |
770 | + | else toBase58String(value(aY.assetId)) | |
771 | + | let bJ = A(an(bC, V)) | |
772 | + | if (if ((bJ != 0)) | |
773 | + | then (height >= bJ) | |
832 | 774 | else false) | |
833 | 775 | then throw("Sale ended.") | |
834 | 776 | else { | |
835 | - | let | |
836 | - | if (!( | |
777 | + | let cQ = A(("current_bidamount_" + V)) | |
778 | + | if (!(bl(bc))) | |
837 | 779 | then throw("asset not accepted") | |
838 | - | else if (!( | |
780 | + | else if (!(bm(aZ))) | |
839 | 781 | then throw("Wrong min sell") | |
840 | 782 | else { | |
841 | - | let | |
842 | - | let | |
843 | - | if ((0 >= | |
783 | + | let bO = A(ad(bC, V)) | |
784 | + | let bP = A(ab(bC, V)) | |
785 | + | if ((0 >= bP)) | |
844 | 786 | then throw("No max edition set for this artwork") | |
845 | - | else if (( | |
787 | + | else if ((bO >= bP)) | |
846 | 788 | then throw("Sold out, you cannot bid") | |
847 | - | else [StringEntry((((((((("bid_" + | |
789 | + | else [StringEntry((((((((("bid_" + V) + "_") + bC) + "_") + T) + "_") + bG) + "_OPEN"), ((((bc + "_") + toString(aZ)) + "_") + toString(bH))), IntegerEntry(("current_bidamount_" + V), (cQ + 1))] | |
848 | 790 | } | |
849 | 791 | } | |
850 | 792 | } | |
851 | 793 | ||
852 | 794 | ||
853 | 795 | ||
854 | - | @Callable( | |
855 | - | func acceptBid ( | |
796 | + | @Callable(aX) | |
797 | + | func acceptBid (V,bC,bD,bE,bw) = bB(aX, V, bC, bD, bE, bw) | |
856 | 798 | ||
857 | 799 | ||
858 | 800 | ||
859 | - | @Callable( | |
860 | - | func cancelBid ( | |
861 | - | let | |
862 | - | let | |
863 | - | let | |
864 | - | let | |
865 | - | if (if (( | |
866 | - | then ( | |
801 | + | @Callable(aX) | |
802 | + | func cancelBid (V,bC,bD,bE) = { | |
803 | + | let cU = bz(aX) | |
804 | + | let bG = cU._1 | |
805 | + | let T = cU._2 | |
806 | + | let bH = cU._3 | |
807 | + | if (if ((T != bE)) | |
808 | + | then (T != bC) | |
867 | 809 | else false) | |
868 | 810 | then throw("You cannot do this action") | |
869 | 811 | else { | |
870 | - | let | |
871 | - | then | |
872 | - | else | |
873 | - | let | |
874 | - | let | |
875 | - | let | |
876 | - | if (( | |
812 | + | let cV = if ((T == bC)) | |
813 | + | then bE | |
814 | + | else T | |
815 | + | let cQ = A(("current_bidamount_" + V)) | |
816 | + | let bq = ((((((("bid_" + V) + "_") + bC) + "_") + bE) + "_") + bD) | |
817 | + | let br = b((bq + "_OPEN")) | |
818 | + | if ((br == "")) | |
877 | 819 | then throw("Bid not found") | |
878 | 820 | else { | |
879 | - | let | |
880 | - | let | |
881 | - | let | |
882 | - | [DeleteEntry(( | |
821 | + | let bs = split(br, "_") | |
822 | + | let bc = bo(bs[0]) | |
823 | + | let cW = "CANCELED" | |
824 | + | [DeleteEntry((bq + "_OPEN")), StringEntry(((bq + "_") + cW), ((br + "_") + toString(bH))), IntegerEntry(("current_bidamount_" + V), (cQ - 1)), ScriptTransfer(Address(fromBase58String(cV)), parseIntValue(bs[1]), bc)] | |
883 | 825 | } | |
884 | 826 | } | |
885 | 827 | } | |
886 | 828 | ||
887 | 829 | ||
888 | - | @Verifier( | |
889 | - | func | |
890 | - | let | |
891 | - | if ($isInstanceOf( | |
830 | + | @Verifier(cX) | |
831 | + | func cY () = { | |
832 | + | let bf = cX | |
833 | + | if ($isInstanceOf(bf, "InvokeScriptTransaction")) | |
892 | 834 | then { | |
893 | - | let | |
894 | - | if (if (if (if (( | |
895 | - | then ( | |
835 | + | let cZ = bf | |
836 | + | if (if (if (if ((cZ.function == "addArtwork")) | |
837 | + | then (cZ.dApp == this) | |
896 | 838 | else false) | |
897 | - | then ( | |
839 | + | then (cZ.fee == 500000) | |
898 | 840 | else false) | |
899 | - | then ( | |
841 | + | then (cZ.feeAssetId == unit) | |
900 | 842 | else false) | |
901 | - | then sigVerify( | |
902 | - | else if (if (if (if (( | |
903 | - | then ( | |
843 | + | then sigVerify(cX.bodyBytes, cX.proofs[0], fromBase58String(cq(cZ.args[11]))) | |
844 | + | else if (if (if (if ((cZ.function == "updateArtwork")) | |
845 | + | then (cZ.dApp == this) | |
904 | 846 | else false) | |
905 | - | then ( | |
847 | + | then (cZ.fee == 500000) | |
906 | 848 | else false) | |
907 | - | then ( | |
849 | + | then (cZ.feeAssetId == unit) | |
908 | 850 | else false) | |
909 | - | then sigVerify( | |
910 | - | else if (if (if (if (( | |
911 | - | then ( | |
851 | + | then sigVerify(cX.bodyBytes, cX.proofs[0], fromBase58String(cq(cZ.args[12]))) | |
852 | + | else if (if (if (if ((cZ.function == "sellArtwork")) | |
853 | + | then (cZ.dApp == this) | |
912 | 854 | else false) | |
913 | - | then ( | |
855 | + | then (cZ.fee == 500000) | |
914 | 856 | else false) | |
915 | - | then ( | |
857 | + | then (cZ.feeAssetId == unit) | |
916 | 858 | else false) | |
917 | - | then sigVerify( | |
918 | - | else if (if (if (if (( | |
919 | - | then ( | |
859 | + | then sigVerify(cX.bodyBytes, cX.proofs[0], fromBase58String(cq(cZ.args[5]))) | |
860 | + | else if (if (if (if ((cZ.function == "acceptBid")) | |
861 | + | then (cZ.dApp == this) | |
920 | 862 | else false) | |
921 | - | then ( | |
863 | + | then (cZ.fee == 500000) | |
922 | 864 | else false) | |
923 | - | then ( | |
865 | + | then (cZ.feeAssetId == unit) | |
924 | 866 | else false) | |
925 | - | then sigVerify_128Kb( | |
926 | - | else sigVerify( | |
867 | + | then sigVerify_128Kb(cX.bodyBytes, cX.proofs[0], fromBase58String(cq(cZ.args[4]))) | |
868 | + | else sigVerify(cX.bodyBytes, cX.proofs[0], cX.senderPublicKey) | |
927 | 869 | } | |
928 | - | else sigVerify( | |
870 | + | else sigVerify(cX.bodyBytes, cX.proofs[0], cX.senderPublicKey) | |
929 | 871 | } | |
930 | 872 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = "2.0.0" | |
5 | 5 | ||
6 | 6 | func b (c) = valueOrElse(getString(this, c), "") | |
7 | 7 | ||
8 | 8 | ||
9 | 9 | let d = false | |
10 | 10 | ||
11 | 11 | let e = value(addressFromString(b("conf_oracle_fee"))) | |
12 | 12 | ||
13 | 13 | let f = value(addressFromString(b("conf_signweb_dapp"))) | |
14 | 14 | ||
15 | 15 | let g = b("conf_fee_receiver") | |
16 | 16 | ||
17 | 17 | let h = if (d) | |
18 | 18 | then value(addressFromString("3Mt4RGMEyjSWYAocTPqd55wdHQQB3PU2UCm")) | |
19 | 19 | else value(addressFromString(b("conf_users_dapp"))) | |
20 | 20 | ||
21 | 21 | let i = value(addressFromString(b("conf_whitelist_dapp"))) | |
22 | 22 | ||
23 | - | let j = | |
23 | + | let j = b("conf_accepted_asset_USDT_PP") | |
24 | 24 | ||
25 | - | let k = | |
25 | + | let k = b("conf_accepted_asset_ART") | |
26 | 26 | ||
27 | - | let l = | |
27 | + | let l = b("conf_accepted_asset_USDC_PP") | |
28 | 28 | ||
29 | - | let m = | |
29 | + | let m = b("conf_accepted_asset_EAST") | |
30 | 30 | ||
31 | - | let n = | |
31 | + | let n = b("conf_accepted_asset_PUZZLE") | |
32 | 32 | ||
33 | - | let o = b("conf_ | |
33 | + | let o = b("conf_accepted_asset_ETH_PP") | |
34 | 34 | ||
35 | - | func p (c) = valueOrErrorMessage(getInteger(e, c), "Integer undefine or 0 in oracle") | |
35 | + | let p = "WAVES" | |
36 | + | ||
37 | + | let q = fromBase58String(j) | |
38 | + | ||
39 | + | let r = fromBase58String(k) | |
40 | + | ||
41 | + | let s = fromBase58String(l) | |
42 | + | ||
43 | + | let t = fromBase58String(m) | |
44 | + | ||
45 | + | let u = fromBase58String(n) | |
46 | + | ||
47 | + | let v = fromBase58String(o) | |
48 | + | ||
49 | + | let w = base58'' | |
50 | + | ||
51 | + | let x = [j, k, l, m, n, p, o] | |
52 | + | ||
53 | + | let y = b("conf_admin_1") | |
54 | + | ||
55 | + | func z (c) = valueOrErrorMessage(getInteger(e, c), "Integer undefine or 0 in oracle") | |
36 | 56 | ||
37 | 57 | ||
38 | - | func | |
58 | + | func A (c) = valueOrElse(getInteger(this, c), 0) | |
39 | 59 | ||
40 | 60 | ||
41 | - | func | |
61 | + | func B (c) = valueOrElse(getInteger(i, c), 0) | |
42 | 62 | ||
43 | 63 | ||
44 | - | func | |
64 | + | func C (c) = valueOrElse(getBoolean(this, c), false) | |
45 | 65 | ||
46 | 66 | ||
47 | - | let | |
67 | + | let D = 8 | |
48 | 68 | ||
49 | - | let | |
69 | + | let E = b("conf_default_licence") | |
50 | 70 | ||
51 | - | let | |
71 | + | let F = b("conf_default_licence_hash") | |
52 | 72 | ||
53 | - | let | |
73 | + | let G = valueOrElse(getBoolean(h, "conf_dapp_is_running"), true) | |
54 | 74 | ||
55 | - | let | |
75 | + | let H = valueOrElse(getString(h, "conf_maintenance_msg"), "") | |
56 | 76 | ||
57 | - | let | |
77 | + | let I = "SUSPENDED" | |
58 | 78 | ||
59 | - | let | |
79 | + | let J = "REMOVED" | |
60 | 80 | ||
61 | - | let | |
81 | + | let K = "UNREGISTERED" | |
62 | 82 | ||
63 | - | let | |
83 | + | let L = "ALLOWED" | |
64 | 84 | ||
65 | - | let | |
85 | + | let M = z(("certification_fee_" + toBase58String(r))) | |
66 | 86 | ||
67 | - | func | |
87 | + | func N (c) = valueOrElse(getInteger(this, c), 1000) | |
68 | 88 | ||
69 | 89 | ||
70 | - | func E (F,G,H) = { | |
71 | - | let I = getString(f, ((("data_fc_" + F) + "_") + G)) | |
72 | - | if ($isInstanceOf(I, "String")) | |
90 | + | func O (P) = if (contains(P, "/")) | |
91 | + | then if (if ((76 > size(P))) | |
92 | + | then (size(split(P, "/")[0]) == 59) | |
93 | + | else false) | |
94 | + | then (16 > size(split(P, "/")[1])) | |
95 | + | else false | |
96 | + | else false | |
97 | + | ||
98 | + | ||
99 | + | func Q (R) = (size(R) == 64) | |
100 | + | ||
101 | + | ||
102 | + | func S (T) = ("user_status_" + T) | |
103 | + | ||
104 | + | ||
105 | + | func U (T,V) = ((("art_date_" + V) + "_") + T) | |
106 | + | ||
107 | + | ||
108 | + | func W (T,V) = ((("art_name_" + V) + "_") + T) | |
109 | + | ||
110 | + | ||
111 | + | func X (T,V) = ((("art_desc_" + V) + "_") + T) | |
112 | + | ||
113 | + | ||
114 | + | func Y (T,V) = ((("art_display_cid_" + V) + "_") + T) | |
115 | + | ||
116 | + | ||
117 | + | func Z (T,V) = ((("art_export_hash_" + V) + "_") + T) | |
118 | + | ||
119 | + | ||
120 | + | func aa (T,V) = ((("art_export_cid_" + V) + "_") + T) | |
121 | + | ||
122 | + | ||
123 | + | func ab (T,V) = ((("art_maxmint_" + V) + "_") + T) | |
124 | + | ||
125 | + | ||
126 | + | func ac (T,V) = ((("art_signid_" + V) + "_") + T) | |
127 | + | ||
128 | + | ||
129 | + | func ad (T,V) = ((("art_issued_" + V) + "_") + T) | |
130 | + | ||
131 | + | ||
132 | + | func ae (T,V) = ((("art_onsale_" + V) + "_") + T) | |
133 | + | ||
134 | + | ||
135 | + | func af (T,V) = ((("art_licence_hash_" + V) + "_") + T) | |
136 | + | ||
137 | + | ||
138 | + | func ag (T,V) = ((("art_licence_cid_" + V) + "_") + T) | |
139 | + | ||
140 | + | ||
141 | + | func ah (T,V) = ((("art_tags_" + V) + "_") + T) | |
142 | + | ||
143 | + | ||
144 | + | func ai (T,V) = ((("art_type_" + V) + "_") + T) | |
145 | + | ||
146 | + | ||
147 | + | func aj (T,V) = ((("art_note_" + V) + "_") + T) | |
148 | + | ||
149 | + | ||
150 | + | func ak (T,V) = ((("art_crawler_cid_" + V) + "_") + T) | |
151 | + | ||
152 | + | ||
153 | + | func al (T,V) = ((("art_royalties_" + V) + "_") + T) | |
154 | + | ||
155 | + | ||
156 | + | func am (T,V) = ((("art_price_" + V) + "_") + T) | |
157 | + | ||
158 | + | ||
159 | + | func an (T,V) = ((("art_endsale_" + V) + "_") + T) | |
160 | + | ||
161 | + | ||
162 | + | func ao (T,V) = ((("art_assetAccepted_" + V) + "_") + T) | |
163 | + | ||
164 | + | ||
165 | + | func ap (T,V) = ((("art_flag_" + V) + "_") + T) | |
166 | + | ||
167 | + | ||
168 | + | func aq (ar) = ("artist_agent_" + ar) | |
169 | + | ||
170 | + | ||
171 | + | func as (ar) = ("artist_agent_primary_" + ar) | |
172 | + | ||
173 | + | ||
174 | + | func at (ar) = ("artist_public_agent_" + ar) | |
175 | + | ||
176 | + | ||
177 | + | func au (ar) = ("artist_public_agent_primary_" + ar) | |
178 | + | ||
179 | + | ||
180 | + | func av (T,aw) = ((("get_hashbytxidaddr_" + aw) + "_") + T) | |
181 | + | ||
182 | + | ||
183 | + | func ax (ay) = ("get_owner_by_hash_" + ay) | |
184 | + | ||
185 | + | ||
186 | + | func az (T,aA) = ((("get_artidbysignid_" + aA) + "_") + T) | |
187 | + | ||
188 | + | ||
189 | + | func aB (aC,aD,aE) = if (!(O(aC))) | |
190 | + | then throw("Wrong Display CID") | |
191 | + | else if (!(O(aD))) | |
192 | + | then throw("Wrong Export CID") | |
193 | + | else if (if ((aE != "")) | |
194 | + | then !(O(aE)) | |
195 | + | else false) | |
196 | + | then throw("Wrong Licence CID") | |
197 | + | else true | |
198 | + | ||
199 | + | ||
200 | + | func aF (aG,aH) = if (!(Q(aG))) | |
201 | + | then throw("Export Hash 64 char. max") | |
202 | + | else if (!(Q(aH))) | |
203 | + | then throw("Licence Hash 64 char. max") | |
204 | + | else true | |
205 | + | ||
206 | + | ||
207 | + | func aI (aJ,aK) = if ((size(aJ) == 0)) | |
208 | + | then throw("Field cannot be is empty") | |
209 | + | else if ((size(aJ) > aK)) | |
210 | + | then throw((aJ + " is too long")) | |
211 | + | else true | |
212 | + | ||
213 | + | ||
214 | + | func aL (T) = { | |
215 | + | let aM = valueOrElse(getString(h, S(T)), K) | |
216 | + | if (if ((aM == K)) | |
217 | + | then true | |
218 | + | else (aM == L)) | |
219 | + | then "Register this account first with \"Account\" tab" | |
220 | + | else if ((aM == I)) | |
221 | + | then "Account suspended" | |
222 | + | else if ((aM == J)) | |
223 | + | then "Account removed" | |
224 | + | else "" | |
225 | + | } | |
226 | + | ||
227 | + | ||
228 | + | func aN (aE,aH) = { | |
229 | + | let P = if ((size(aE) == 0)) | |
230 | + | then E | |
231 | + | else aE | |
232 | + | let R = if ((size(aH) == 0)) | |
233 | + | then F | |
234 | + | else aH | |
235 | + | $Tuple2(P, R) | |
236 | + | } | |
237 | + | ||
238 | + | ||
239 | + | func aO (T,aC,aD,aP,aG,aQ,aR,aS,aT,aU) = { | |
240 | + | let aV = aL(T) | |
241 | + | if ((aV != "")) | |
242 | + | then throw(aV) | |
243 | + | else if ((size(aC) == 0)) | |
244 | + | then throw("Display CID cannot be empty") | |
245 | + | else if (!(aB(aC, aD, aP))) | |
246 | + | then throw("Problem with CID") | |
247 | + | else if (!(aF(aG, aQ))) | |
248 | + | then throw("Problem with Hashes") | |
249 | + | else if (!(aI(aR, 100))) | |
250 | + | then throw("100 Char. max name") | |
251 | + | else if (!(aI(aS, 1000))) | |
252 | + | then throw("1000 Char. max description") | |
253 | + | else if (if ((0 > aU)) | |
254 | + | then true | |
255 | + | else (aU > 1000)) | |
256 | + | then throw("Royalties cannot be less than 0% or higher than 10%") | |
257 | + | else if ((size(split(aT, ",")) > 5)) | |
258 | + | then throw("5 tags max.") | |
259 | + | else "" | |
260 | + | } | |
261 | + | ||
262 | + | ||
263 | + | func aW (aX) = if ((size(aX.payments) == 0)) | |
264 | + | then throw("No payment attached") | |
265 | + | else { | |
266 | + | let aY = value(aX.payments[0]) | |
267 | + | let aZ = value(aY.amount) | |
268 | + | $Tuple2(aY, aZ) | |
269 | + | } | |
270 | + | ||
271 | + | ||
272 | + | func ba (aX) = { | |
273 | + | let bb = aW(aX) | |
274 | + | let aY = bb._1 | |
275 | + | let aZ = bb._2 | |
276 | + | let bc = if (if (isDefined(aY.assetId)) | |
277 | + | then (aY.assetId == r) | |
278 | + | else false) | |
279 | + | then aY.assetId | |
280 | + | else throw("Only SIGN token accepted as transaction fee") | |
281 | + | if ((aZ != M)) | |
282 | + | then throw(("Payment amount should be " + toString(M))) | |
283 | + | else $Tuple2(aZ, bc) | |
284 | + | } | |
285 | + | ||
286 | + | ||
287 | + | func bd (be,V) = { | |
288 | + | let bf = getInteger(this, ad(be, V)) | |
289 | + | if ($isInstanceOf(bf, "Int")) | |
73 | 290 | then { | |
74 | - | let | |
75 | - | if ( | |
291 | + | let bg = bf | |
292 | + | if ((bg != 0)) | |
76 | 293 | then true | |
77 | 294 | else false | |
78 | 295 | } | |
79 | 296 | else false | |
80 | 297 | } | |
81 | 298 | ||
82 | 299 | ||
83 | - | func K (L) = if (contains(L, "/")) | |
84 | - | then if (if ((76 > size(L))) | |
85 | - | then (size(split(L, "/")[0]) == 59) | |
300 | + | func bh (aX,bi,bj) = { | |
301 | + | let bk = aW(aX) | |
302 | + | let aY = bk._1 | |
303 | + | let aZ = bk._2 | |
304 | + | let bc = if (!(isDefined(aY.assetId))) | |
305 | + | then unit | |
306 | + | else if (if ((size(bi) > 0)) | |
307 | + | then (toBase58String(value(aY.assetId)) == bi) | |
308 | + | else false) | |
309 | + | then aY.assetId | |
310 | + | else throw("Wrong asset id") | |
311 | + | if (if ((bc == unit)) | |
312 | + | then (bi != "") | |
86 | 313 | else false) | |
87 | - | then (16 > size(split(L, "/")[1])) | |
88 | - | else false | |
89 | - | else false | |
90 | - | ||
91 | - | ||
92 | - | func M (N) = (size(N) == 64) | |
93 | - | ||
94 | - | ||
95 | - | func O (P) = ("user_status_" + P) | |
96 | - | ||
97 | - | ||
98 | - | func Q (P,R) = ((("art_date_" + R) + "_") + P) | |
99 | - | ||
100 | - | ||
101 | - | func S (P,R) = ((("art_name_" + R) + "_") + P) | |
102 | - | ||
103 | - | ||
104 | - | func T (P,R) = ((("art_desc_" + R) + "_") + P) | |
105 | - | ||
106 | - | ||
107 | - | func U (P,R) = ((("art_display_cid_" + R) + "_") + P) | |
108 | - | ||
109 | - | ||
110 | - | func V (P,R) = ((("art_export_hash_" + R) + "_") + P) | |
111 | - | ||
112 | - | ||
113 | - | func W (P,R) = ((("art_export_cid_" + R) + "_") + P) | |
114 | - | ||
115 | - | ||
116 | - | func X (P,R) = ((("art_maxmint_" + R) + "_") + P) | |
117 | - | ||
118 | - | ||
119 | - | func Y (P,R) = ((("art_signid_" + R) + "_") + P) | |
120 | - | ||
121 | - | ||
122 | - | func Z (P,R) = ((("art_issued_" + R) + "_") + P) | |
123 | - | ||
124 | - | ||
125 | - | func aa (P,R) = ((("art_onsale_" + R) + "_") + P) | |
126 | - | ||
127 | - | ||
128 | - | func ab (P,R) = ((("art_licence_hash_" + R) + "_") + P) | |
129 | - | ||
130 | - | ||
131 | - | func ac (P,R) = ((("art_licence_cid_" + R) + "_") + P) | |
132 | - | ||
133 | - | ||
134 | - | func ad (P,R) = ((("art_tags_" + R) + "_") + P) | |
135 | - | ||
136 | - | ||
137 | - | func ae (P,R) = ((("art_type_" + R) + "_") + P) | |
138 | - | ||
139 | - | ||
140 | - | func af (P,R) = ((("art_note_" + R) + "_") + P) | |
141 | - | ||
142 | - | ||
143 | - | func ag (P,R) = ((("art_crawler_cid_" + R) + "_") + P) | |
144 | - | ||
145 | - | ||
146 | - | func ah (P,R) = ((("art_royalties_" + R) + "_") + P) | |
147 | - | ||
148 | - | ||
149 | - | func ai (P,R) = ((("art_price_" + R) + "_") + P) | |
150 | - | ||
151 | - | ||
152 | - | func aj (P,R) = ((("art_endsale_" + R) + "_") + P) | |
153 | - | ||
154 | - | ||
155 | - | func ak (P,R) = ((("art_assetAccepted_" + R) + "_") + P) | |
156 | - | ||
157 | - | ||
158 | - | func al (P,R) = ((("art_flag_" + R) + "_") + P) | |
159 | - | ||
160 | - | ||
161 | - | func am (an) = ("artist_agent_" + an) | |
162 | - | ||
163 | - | ||
164 | - | func ao (an) = ("artist_agent_primary_" + an) | |
165 | - | ||
166 | - | ||
167 | - | func ap (an) = ("artist_public_agent_" + an) | |
168 | - | ||
169 | - | ||
170 | - | func aq (an) = ("artist_public_agent_primary_" + an) | |
171 | - | ||
172 | - | ||
173 | - | func ar (P,as) = ((("get_hashbytxidaddr_" + as) + "_") + P) | |
174 | - | ||
175 | - | ||
176 | - | func at (H) = ("get_owner_by_hash_" + H) | |
177 | - | ||
178 | - | ||
179 | - | func au (P,av) = ((("get_artidbysignid_" + av) + "_") + P) | |
180 | - | ||
181 | - | ||
182 | - | func aw (H,P) = ("get_txid_by_hash_owner_" + toBase58String(sha256_16Kb(toBytes((H + P))))) | |
183 | - | ||
184 | - | ||
185 | - | func ax (ay,az,aA) = if (!(K(ay))) | |
186 | - | then throw("Wrong Display CID") | |
187 | - | else if (!(K(az))) | |
188 | - | then throw("Wrong Export CID") | |
189 | - | else if (if ((aA != "")) | |
190 | - | then !(K(aA)) | |
191 | - | else false) | |
192 | - | then throw("Wrong Licence CID") | |
193 | - | else true | |
194 | - | ||
195 | - | ||
196 | - | func aB (aC,aD) = if (!(M(aC))) | |
197 | - | then throw("Export Hash 64 char. max") | |
198 | - | else if (!(M(aD))) | |
199 | - | then throw("Licence Hash 64 char. max") | |
200 | - | else true | |
201 | - | ||
202 | - | ||
203 | - | func aE (aF,aG) = if ((size(aF) == 0)) | |
204 | - | then throw("Field cannot be is empty") | |
205 | - | else if ((size(aF) > aG)) | |
206 | - | then throw((aF + " is too long")) | |
207 | - | else true | |
208 | - | ||
209 | - | ||
210 | - | func aH (P) = { | |
211 | - | let aI = valueOrElse(getString(h, O(P)), A) | |
212 | - | if (if ((aI == A)) | |
213 | - | then true | |
214 | - | else (aI == B)) | |
215 | - | then "Register this account first with \"Account\" tab" | |
216 | - | else if ((aI == y)) | |
217 | - | then "Account suspended" | |
218 | - | else if ((aI == z)) | |
219 | - | then "Account removed" | |
220 | - | else "" | |
314 | + | then throw("Wrong asset id") | |
315 | + | else if ((bj != aZ)) | |
316 | + | then throw("Payment don't match") | |
317 | + | else $Tuple2(aZ, bc) | |
221 | 318 | } | |
222 | 319 | ||
223 | 320 | ||
224 | - | func aJ (aA,aD) = { | |
225 | - | let L = if ((size(aA) == 0)) | |
226 | - | then u | |
227 | - | else aA | |
228 | - | let N = if ((size(aD) == 0)) | |
229 | - | then v | |
230 | - | else aD | |
231 | - | $Tuple2(L, N) | |
232 | - | } | |
233 | - | ||
234 | - | ||
235 | - | func aK (P,ay,az,aL,aC,aM,aN,aO,aP,aQ) = { | |
236 | - | let aR = aH(P) | |
237 | - | if ((aR != "")) | |
238 | - | then throw(aR) | |
239 | - | else if ((size(ay) == 0)) | |
240 | - | then throw("Display CID cannot be empty") | |
241 | - | else if (!(ax(ay, az, aL))) | |
242 | - | then throw("Problem with CID") | |
243 | - | else if (!(aB(aC, aM))) | |
244 | - | then throw("Problem with Hashes") | |
245 | - | else if (!(aE(aN, 100))) | |
246 | - | then throw("100 Char. max name") | |
247 | - | else if (!(aE(aO, 1000))) | |
248 | - | then throw("1000 Char. max description") | |
249 | - | else if (if ((0 > aQ)) | |
250 | - | then true | |
251 | - | else (aQ > 1000)) | |
252 | - | then throw("Royalties cannot be less than 0% or higher than 10%") | |
253 | - | else if ((size(split(aP, ",")) > 5)) | |
254 | - | then throw("5 tags max.") | |
255 | - | else "" | |
256 | - | } | |
257 | - | ||
258 | - | ||
259 | - | func aS (aT) = if ((size(aT.payments) == 0)) | |
260 | - | then throw("No payment attached") | |
261 | - | else { | |
262 | - | let aU = value(aT.payments[0]) | |
263 | - | let aV = value(aU.amount) | |
264 | - | $Tuple2(aU, aV) | |
265 | - | } | |
266 | - | ||
267 | - | ||
268 | - | func aW (aT) = { | |
269 | - | let aX = aS(aT) | |
270 | - | let aU = aX._1 | |
271 | - | let aV = aX._2 | |
272 | - | let aY = if (if (isDefined(aU.assetId)) | |
273 | - | then (aU.assetId == j) | |
274 | - | else false) | |
275 | - | then aU.assetId | |
276 | - | else throw("Only SIGN token accepted as transaction fee") | |
277 | - | if ((aV != C)) | |
278 | - | then throw(("Payment amount should be " + toString(C))) | |
279 | - | else $Tuple2(aV, aY) | |
280 | - | } | |
281 | - | ||
282 | - | ||
283 | - | func aZ (ba,R) = { | |
284 | - | let I = getInteger(this, Z(ba, R)) | |
285 | - | if ($isInstanceOf(I, "Int")) | |
286 | - | then { | |
287 | - | let bb = I | |
288 | - | if ((bb != 0)) | |
289 | - | then true | |
290 | - | else false | |
291 | - | } | |
292 | - | else false | |
293 | - | } | |
294 | - | ||
295 | - | ||
296 | - | func bc (aT,bd,be) = { | |
297 | - | let bf = aS(aT) | |
298 | - | let aU = bf._1 | |
299 | - | let aV = bf._2 | |
300 | - | let aY = if (!(isDefined(aU.assetId))) | |
301 | - | then unit | |
302 | - | else if (if ((size(bd) > 0)) | |
303 | - | then (toBase58String(value(aU.assetId)) == bd) | |
304 | - | else false) | |
305 | - | then aU.assetId | |
306 | - | else throw("Wrong asset id") | |
307 | - | if (if ((aY == unit)) | |
308 | - | then (bd != "") | |
309 | - | else false) | |
310 | - | then throw("Wrong asset id") | |
311 | - | else if ((be != aV)) | |
312 | - | then throw("Payment don't match") | |
313 | - | else $Tuple2(aV, aY) | |
314 | - | } | |
315 | - | ||
316 | - | ||
317 | - | func bg (aY) = if (if (if (if (if (if ((aY != toBase58String(j))) | |
318 | - | then (aY != toBase58String(n)) | |
319 | - | else false) | |
320 | - | then (aY != "WAVES") | |
321 | - | else false) | |
322 | - | then (aY != toBase58String(k)) | |
323 | - | else false) | |
324 | - | then (aY != toBase58String(l)) | |
325 | - | else false) | |
326 | - | then (aY != toBase58String(m)) | |
327 | - | else false) | |
328 | - | then throw("Only SIGN, USDN,USDT or WAVES accepted") | |
321 | + | func bl (bc) = if (!(containsElement(x, bc))) | |
322 | + | then throw("Only $ART, USDT-PP, USDC-PP, EAST, PUZZLE, ETH or WAVES accepted") | |
329 | 323 | else true | |
330 | 324 | ||
331 | 325 | ||
332 | - | func bh (aY,bi) = { | |
333 | - | let bj = if (d) | |
334 | - | then 10 | |
335 | - | else p("waves_min_sell") | |
336 | - | let bk = 1000000 | |
337 | - | let bl = if (d) | |
338 | - | then 1 | |
339 | - | else (C * 2) | |
340 | - | if (if (if (if (if (if (if ((aY == toBase58String(k))) | |
341 | - | then (bk > bi) | |
342 | - | else false) | |
343 | - | then (bi != 0) | |
344 | - | else false) | |
345 | - | then true | |
346 | - | else if (if ((aY == toBase58String(l))) | |
347 | - | then (bk > bi) | |
348 | - | else false) | |
349 | - | then (bi != 0) | |
350 | - | else false) | |
351 | - | then true | |
352 | - | else if (if ((aY == toBase58String(m))) | |
353 | - | then (bk > bi) | |
354 | - | else false) | |
355 | - | then (bi != 0) | |
356 | - | else false) | |
357 | - | then true | |
358 | - | else if (if ((aY == toBase58String(j))) | |
359 | - | then (bl > bi) | |
360 | - | else false) | |
361 | - | then (bi != 0) | |
362 | - | else false) | |
363 | - | then true | |
364 | - | else if (if (if ((aY == toBase58String(n))) | |
365 | - | then true | |
366 | - | else (aY == "WAVES")) | |
367 | - | then (bj > bi) | |
368 | - | else false) | |
369 | - | then (bi != 0) | |
370 | - | else false) | |
371 | - | then throw("Wrong minimum sell price") | |
372 | - | else true | |
373 | - | } | |
326 | + | func bm (bn) = if ((0 >= bn)) | |
327 | + | then throw("Wrong minimum sell price") | |
328 | + | else true | |
374 | 329 | ||
375 | 330 | ||
376 | - | func | |
331 | + | func bo (bc) = if ((bc == "WAVES")) | |
377 | 332 | then unit | |
378 | - | else fromBase58String( | |
333 | + | else fromBase58String(bc) | |
379 | 334 | ||
380 | 335 | ||
381 | - | func | |
382 | - | let | |
383 | - | if (( | |
336 | + | func bp (bq) = { | |
337 | + | let br = b((bq + "_OPEN")) | |
338 | + | if ((br == "")) | |
384 | 339 | then throw("Bid not found") | |
385 | 340 | else { | |
386 | - | let | |
387 | - | let | |
388 | - | let | |
389 | - | if ((0 >= | |
341 | + | let bs = split(br, "_") | |
342 | + | let bt = parseIntValue(bs[1]) | |
343 | + | let bu = bo(bs[0]) | |
344 | + | if ((0 >= bt)) | |
390 | 345 | then throw("Wrong amount") | |
391 | - | else $Tuple2( | |
346 | + | else $Tuple2(bt, bu) | |
392 | 347 | } | |
393 | 348 | } | |
394 | 349 | ||
395 | 350 | ||
396 | - | func | |
397 | - | then throw( | |
351 | + | func bv (aX,bw) = if (!(G)) | |
352 | + | then throw(H) | |
398 | 353 | else { | |
399 | - | let | |
400 | - | then valueOrElse( | |
354 | + | let bx = if ((bw != "")) | |
355 | + | then valueOrElse(B((toString(addressFromPublicKey(fromBase58String(bw))) + "_free_txs")), 0) | |
401 | 356 | else 0 | |
402 | - | let | |
403 | - | then ( | |
357 | + | let T = if (if ((toBase58String(aX.caller.bytes) == toString(this))) | |
358 | + | then (bx > 0) | |
404 | 359 | else false) | |
405 | - | then toString(addressFromPublicKey(fromBase58String( | |
406 | - | else toBase58String( | |
407 | - | let | |
408 | - | then ( | |
360 | + | then toString(addressFromPublicKey(fromBase58String(bw))) | |
361 | + | else toBase58String(aX.caller.bytes) | |
362 | + | let by = if (if ((bw != "")) | |
363 | + | then (bx > 0) | |
409 | 364 | else false) | |
410 | - | then invoke(i, "useFreeTx", [toString(addressFromPublicKey(fromBase58String( | |
365 | + | then invoke(i, "useFreeTx", [toString(addressFromPublicKey(fromBase58String(bw)))], nil) | |
411 | 366 | else unit | |
412 | - | if (( | |
413 | - | then $Tuple4(toBase58String( | |
367 | + | if ((by == by)) | |
368 | + | then $Tuple4(toBase58String(aX.transactionId), T, lastBlock.timestamp, (bx > 0)) | |
414 | 369 | else throw("Strict value is not equal to itself.") | |
415 | 370 | } | |
416 | 371 | ||
417 | 372 | ||
418 | - | func | |
419 | - | then throw( | |
420 | - | else $Tuple3(toBase58String( | |
373 | + | func bz (aX) = if (!(G)) | |
374 | + | then throw(H) | |
375 | + | else $Tuple3(toBase58String(aX.transactionId), toBase58String(aX.caller.bytes), lastBlock.timestamp) | |
421 | 376 | ||
422 | 377 | ||
423 | - | func by (aT,R,bz,bA,bB,bu) = { | |
424 | - | let bC = bt(aT, bu) | |
425 | - | let bD = bC._1 | |
426 | - | let P = bC._2 | |
427 | - | let bE = bC._3 | |
428 | - | let bv = bC._4 | |
429 | - | let bF = if (if (if ((P == bz)) | |
430 | - | then (bB != "") | |
378 | + | func bA (bc) = { | |
379 | + | let bf = bc | |
380 | + | if ($isInstanceOf(bf, "ByteVector")) | |
381 | + | then { | |
382 | + | let bg = bf | |
383 | + | assetBalance(this, bg) | |
384 | + | } | |
385 | + | else wavesBalance(this).available | |
386 | + | } | |
387 | + | ||
388 | + | ||
389 | + | func bB (aX,V,bC,bD,bE,bw) = { | |
390 | + | let bF = bv(aX, bw) | |
391 | + | let bG = bF._1 | |
392 | + | let T = bF._2 | |
393 | + | let bH = bF._3 | |
394 | + | let bx = bF._4 | |
395 | + | let bI = if (if (if ((T == bC)) | |
396 | + | then (bE != "") | |
431 | 397 | else false) | |
432 | - | then ( | |
398 | + | then (bD != "") | |
433 | 399 | else false) | |
434 | 400 | then true | |
435 | 401 | else false | |
436 | - | if (if ( | |
437 | - | then ( | |
402 | + | if (if (bI) | |
403 | + | then (T != bC) | |
438 | 404 | else false) | |
439 | 405 | then throw("You cannot do this action") | |
440 | 406 | else { | |
441 | - | let | |
442 | - | if (if (if (( | |
443 | - | then (height >= | |
407 | + | let bJ = A(an(T, V)) | |
408 | + | if (if (if ((bJ != 0)) | |
409 | + | then (height >= bJ) | |
444 | 410 | else false) | |
445 | - | then !( | |
411 | + | then !(bI) | |
446 | 412 | else false) | |
447 | 413 | then throw("Sale ended.") | |
448 | 414 | else { | |
449 | - | let bH = (P == bz) | |
450 | - | let bI = q("total_nft_issued") | |
451 | - | let F = b(Y(bz, R)) | |
452 | - | let bJ = b(S(bz, R)) | |
453 | - | if ((bJ == "")) | |
415 | + | let bK = (T == bC) | |
416 | + | let bL = A("total_nft_issued") | |
417 | + | let bM = b(W(bC, V)) | |
418 | + | if ((bM == "")) | |
454 | 419 | then throw("Art doesn't exist") | |
455 | 420 | else { | |
456 | - | let | |
457 | - | let | |
458 | - | let | |
459 | - | then ( | |
460 | - | else | |
461 | - | let | |
462 | - | then toBase58String( | |
463 | - | else b( | |
464 | - | let | |
465 | - | if (if (if (!( | |
466 | - | then !( | |
421 | + | let bN = C(ae(bC, V)) | |
422 | + | let bO = A(ad(bC, V)) | |
423 | + | let bj = if (bK) | |
424 | + | then (M * 2) | |
425 | + | else A(am(bC, V)) | |
426 | + | let bi = if (bK) | |
427 | + | then toBase58String(r) | |
428 | + | else b(ao(bC, V)) | |
429 | + | let bP = A(ab(bC, V)) | |
430 | + | if (if (if (!(bI)) | |
431 | + | then !(bK) | |
467 | 432 | else false) | |
468 | - | then if (if ((0 >= | |
433 | + | then if (if ((0 >= bj)) | |
469 | 434 | then true | |
470 | - | else !( | |
435 | + | else !(bN)) | |
471 | 436 | then true | |
472 | - | else (0 >= | |
437 | + | else (0 >= bP) | |
473 | 438 | else false) | |
474 | 439 | then throw("Art not for sale") | |
475 | - | else if (if (if (!( | |
476 | - | then | |
440 | + | else if (if (if (!(bI)) | |
441 | + | then bK | |
477 | 442 | else false) | |
478 | - | then (0 >= | |
443 | + | then (0 >= bP) | |
479 | 444 | else false) | |
480 | 445 | then throw("Max issuable not set") | |
481 | 446 | else { | |
482 | - | let | |
483 | - | if (if ( | |
484 | - | then ( | |
447 | + | let aV = aL(bC) | |
448 | + | if (if (bI) | |
449 | + | then (aV != "") | |
485 | 450 | else false) | |
486 | - | then throw( | |
451 | + | then throw(aV) | |
487 | 452 | else { | |
488 | - | let | |
489 | - | let | |
490 | - | then | |
491 | - | else | |
492 | - | let | |
493 | - | let | |
494 | - | let | |
495 | - | let | |
496 | - | let | |
497 | - | let | |
498 | - | let | |
499 | - | let | |
500 | - | let | |
501 | - | then ( | |
453 | + | let bq = ((((((("bid_" + V) + "_") + bC) + "_") + bE) + "_") + bD) | |
454 | + | let bQ = if (bI) | |
455 | + | then bp(bq) | |
456 | + | else bh(aX, bi, bj) | |
457 | + | let aZ = bQ._1 | |
458 | + | let bc = bQ._2 | |
459 | + | let bR = valueOrElse(getString(h, aq(bC)), g) | |
460 | + | let bS = valueOrElse(getInteger(h, as(bC)), 0) | |
461 | + | let bT = valueOrElse(getString(h, at(bC)), g) | |
462 | + | let bU = valueOrElse(getInteger(h, au(bC)), 0) | |
463 | + | let bV = B(bC) | |
464 | + | let bW = fraction(aZ, D, 100) | |
465 | + | let bX = if (if (if ((bR != g)) | |
466 | + | then (bS > 0) | |
502 | 467 | else false) | |
503 | - | then (height > | |
468 | + | then (height > bV) | |
504 | 469 | else false) | |
505 | - | then fraction( | |
470 | + | then fraction(aZ, bS, 10000) | |
506 | 471 | else 0 | |
507 | - | let | |
508 | - | then ( | |
472 | + | let bY = if (if (if ((bT != g)) | |
473 | + | then (bU > 0) | |
509 | 474 | else false) | |
510 | - | then (height > | |
475 | + | then (height > bV) | |
511 | 476 | else false) | |
512 | - | then fraction( | |
477 | + | then fraction(aZ, bU, 10000) | |
513 | 478 | else 0 | |
514 | - | let | |
515 | - | if (( | |
479 | + | let bZ = (aZ - bW) | |
480 | + | if ((bO == bP)) | |
516 | 481 | then throw("Art sold out") | |
517 | 482 | else { | |
518 | - | let bX = (bL + 1) | |
519 | - | let bY = ((((((((((("Creator: " + bz) + ", | |
520 | - | ArtID: ") + R) + ", | |
521 | - | SignID: ") + F) + ", | |
522 | - | Artwork name: ") + bJ) + ", | |
523 | - | Issue: ") + toString(bX)) + "/") + toString(bM)) | |
524 | - | let bZ = Issue(("SA_" + toString((bI + 1))), bY, 1, 0, false) | |
525 | - | let ca = calculateAssetId(bZ) | |
526 | - | let cb = if (if ((bX == bM)) | |
483 | + | let ca = (bO + 1) | |
484 | + | let cb = ((((((((("Creator: " + bC) + ", | |
485 | + | ArtID: ") + V) + ", | |
486 | + | Artwork name: ") + bM) + ", | |
487 | + | Issue: ") + toString(ca)) + "/") + toString(bP)) | |
488 | + | let cc = Issue(("SA_" + toString((bL + 1))), cb, 1, 0, false) | |
489 | + | let cd = calculateAssetId(cc) | |
490 | + | let ce = if (if ((ca == bP)) | |
527 | 491 | then true | |
528 | - | else !( | |
492 | + | else !(bN)) | |
529 | 493 | then false | |
530 | 494 | else true | |
531 | - | let | |
532 | - | then ( | |
495 | + | let cf = if (if (if ((T == bC)) | |
496 | + | then (bE != "") | |
533 | 497 | else false) | |
534 | - | then ( | |
498 | + | then (bD != "") | |
535 | 499 | else false) | |
536 | - | then addressFromStringValue( | |
537 | - | else | |
538 | - | let | |
500 | + | then addressFromStringValue(bE) | |
501 | + | else aX.caller | |
502 | + | let cg = if (!(isDefined(bc))) | |
539 | 503 | then "WAVES" | |
540 | - | else toBase58String(value( | |
541 | - | let | |
542 | - | let | |
543 | - | let | |
544 | - | let | |
545 | - | let | |
546 | - | then (((((((((( | |
547 | - | else ((((((((((toString( | |
548 | - | let | |
549 | - | let | |
550 | - | then [ScriptTransfer(Address(fromBase58String(g)), ( | |
551 | - | else [ScriptTransfer(Address(fromBase58String(g)), | |
552 | - | let | |
553 | - | then [ScriptTransfer(Address(fromBase58String( | |
554 | - | else [ScriptTransfer(Address(fromBase58String( | |
555 | - | let | |
556 | - | then [ScriptTransfer(Address(fromBase58String( | |
504 | + | else toBase58String(value(bc)) | |
505 | + | let br = b((bq + "_OPEN")) | |
506 | + | let ch = DeleteEntry((bq + "_OPEN")) | |
507 | + | let ci = StringEntry((bq + "_CLOSED"), ((br + "_") + toString(bH))) | |
508 | + | let cj = ((((((("art_sold_" + toString(ca)) + "_of_") + toString(bP)) + "_") + V) + "_") + bC) | |
509 | + | let ck = if (!(bI)) | |
510 | + | then ((((((((((T + "_") + toString(bH)) + "_") + bG) + "_") + toString(bj)) + "_") + bi) + "_") + toBase58String(cd)) | |
511 | + | else ((((((((((toString(cf) + "_") + toString(bH)) + "_") + bG) + "_") + toString(aZ)) + "_") + cg) + "_") + toBase58String(cd)) | |
512 | + | let cl = StringEntry(cj, ck) | |
513 | + | let cm = if ((bX != 0)) | |
514 | + | then [ScriptTransfer(Address(fromBase58String(g)), (bW - bX), bc), ScriptTransfer(Address(fromBase58String(bR)), bX, bc)] | |
515 | + | else [ScriptTransfer(Address(fromBase58String(g)), bW, bc)] | |
516 | + | let cn = if ((bY != 0)) | |
517 | + | then [ScriptTransfer(Address(fromBase58String(bT)), bY, bc), ScriptTransfer(Address(fromBase58String(bC)), (bZ - bY), bc)] | |
518 | + | else [ScriptTransfer(Address(fromBase58String(bC)), bZ, bc)] | |
519 | + | let co = if (bx) | |
520 | + | then [ScriptTransfer(Address(fromBase58String(T)), 0, unit)] | |
557 | 521 | else nil | |
558 | - | let | |
559 | - | if ( | |
560 | - | then [ci, | |
561 | - | else | |
522 | + | let cp = ((([IntegerEntry(ad(bC, V), ca), StringEntry(("nft_" + toBase58String(cd)), cj), IntegerEntry("total_nft_issued", (bL + 1)), IntegerEntry(an(bC, V), 0), BooleanEntry(ae(bC, V), ce), cc, ScriptTransfer(cf, 1, cd)] ++ cm) ++ cn) ++ co) | |
523 | + | if (bI) | |
524 | + | then [cl, ci, ch] :: cp | |
525 | + | else cl :: cp | |
562 | 526 | } | |
563 | 527 | } | |
564 | 528 | } | |
565 | 529 | } | |
566 | 530 | } | |
567 | 531 | } | |
568 | 532 | } | |
569 | 533 | ||
570 | 534 | ||
571 | - | func | |
572 | - | let | |
573 | - | if ($isInstanceOf( | |
535 | + | func cq (cr) = { | |
536 | + | let bf = cr | |
537 | + | if ($isInstanceOf(bf, "String")) | |
574 | 538 | then { | |
575 | - | let | |
576 | - | | |
539 | + | let cs = bf | |
540 | + | cs | |
577 | 541 | } | |
578 | 542 | else throw("Sponsored Public Key String expected") | |
579 | 543 | } | |
580 | 544 | ||
581 | 545 | ||
582 | - | @Callable( | |
583 | - | func setConf (c, | |
584 | - | let | |
585 | - | if (containsElement([ | |
546 | + | @Callable(ct) | |
547 | + | func setConf (c,cu) = { | |
548 | + | let T = toString(ct.caller) | |
549 | + | if (containsElement([y, toString(this)], T)) | |
586 | 550 | then if (contains(c, "conf_")) | |
587 | - | then [StringEntry(c, | |
551 | + | then [StringEntry(c, cu)] | |
588 | 552 | else throw("Entries starting with conf_ only") | |
589 | 553 | else throw("You are not allowed to change this") | |
590 | 554 | } | |
591 | 555 | ||
592 | 556 | ||
593 | 557 | ||
594 | - | @Callable(aT) | |
595 | - | func addArtwork (H,F,aN,aO,aP,cs,ay,aC,az,aD,aA,ct,aQ,bu) = { | |
596 | - | let cu = bt(aT, bu) | |
597 | - | let R = cu._1 | |
598 | - | let P = cu._2 | |
599 | - | let bE = cu._3 | |
600 | - | let bv = cu._4 | |
601 | - | if (!(M(H))) | |
602 | - | then throw("Hash should be 64 characters maximum") | |
558 | + | @Callable(aX) | |
559 | + | func addArtwork (aR,aS,aT,cv,aC,aG,aD,aH,aE,cw,aU,bw) = { | |
560 | + | let cx = bv(aX, bw) | |
561 | + | let V = cx._1 | |
562 | + | let T = cx._2 | |
563 | + | let bH = cx._3 | |
564 | + | let bx = cx._4 | |
565 | + | let cy = aN(aE, aH) | |
566 | + | let aP = cy._1 | |
567 | + | let aQ = cy._2 | |
568 | + | let cz = aO(T, aC, aD, aP, aG, aQ, aR, aS, aT, aU) | |
569 | + | if ((cz != "")) | |
570 | + | then throw("Something went wrong!") | |
603 | 571 | else { | |
604 | - | let cv = aJ(aA, aD) | |
605 | - | let aL = cv._1 | |
606 | - | let aM = cv._2 | |
607 | - | let cw = aK(P, ay, az, aL, aC, aM, aN, aO, aP, aQ) | |
608 | - | if ((cw != "")) | |
609 | - | then throw("Something went wrong!") | |
572 | + | let cA = (B((T + "_free_drops")) > 0) | |
573 | + | let cB = if (cA) | |
574 | + | then $Tuple2(0, r) | |
575 | + | else ba(aX) | |
576 | + | let aZ = cB._1 | |
577 | + | let bc = cB._2 | |
578 | + | if (!(isDefined(aZ))) | |
579 | + | then throw("Something went wrong") | |
610 | 580 | else { | |
611 | - | let cx = (r((P + "_free_drops")) > 0) | |
612 | - | let cy = if (cx) | |
613 | - | then $Tuple2(0, F) | |
614 | - | else aW(aT) | |
615 | - | let aV = cy._1 | |
616 | - | let aY = cy._2 | |
617 | - | if (!(isDefined(aV))) | |
618 | - | then throw("Something went wrong") | |
619 | - | else { | |
620 | - | let cz = b(aw(H, P)) | |
621 | - | if ((cz != "")) | |
622 | - | then throw("You already added it") | |
623 | - | else { | |
624 | - | let cA = b(at(H)) | |
625 | - | if ((cA != "")) | |
626 | - | then throw("Hash already registered") | |
627 | - | else { | |
628 | - | let cB = E(F, P, H) | |
629 | - | if (!(cB)) | |
630 | - | then throw("Sign Certificate not found for this address.") | |
631 | - | else { | |
632 | - | let cC = if (cx) | |
633 | - | then invoke(i, "useFreeDrop", [P], nil) | |
634 | - | else unit | |
635 | - | if ((cC == cC)) | |
636 | - | then { | |
637 | - | let cl = if (bv) | |
638 | - | then [ScriptTransfer(Address(fromBase58String(P)), 0, unit)] | |
639 | - | else nil | |
640 | - | ([StringEntry(at(H), P), StringEntry(aw(H, P), R), IntegerEntry(Q(P, R), bE), StringEntry(S(P, R), aN), StringEntry(T(P, R), aO), StringEntry(U(P, R), ay), StringEntry(W(P, R), az), StringEntry(V(P, R), aC), StringEntry(ab(P, R), aM), StringEntry(ac(P, R), aL), StringEntry(ae(P, R), cs), StringEntry(ad(P, R), aP), IntegerEntry(X(P, R), 0), StringEntry(Y(P, R), F), IntegerEntry(Z(P, R), 0), BooleanEntry(aa(P, R), false), StringEntry(au(P, F), R), StringEntry(ar(P, R), H), StringEntry(ag(P, R), ct), IntegerEntry(ah(P, R), aQ), ScriptTransfer(Address(fromBase58String(g)), aV, j)] ++ cl) | |
641 | - | } | |
642 | - | else throw("Strict value is not equal to itself.") | |
643 | - | } | |
644 | - | } | |
645 | - | } | |
581 | + | let cC = if (cA) | |
582 | + | then invoke(i, "useFreeDrop", [T], nil) | |
583 | + | else unit | |
584 | + | if ((cC == cC)) | |
585 | + | then { | |
586 | + | let co = if (bx) | |
587 | + | then [ScriptTransfer(Address(fromBase58String(T)), 0, unit)] | |
588 | + | else nil | |
589 | + | ([IntegerEntry(U(T, V), bH), StringEntry(W(T, V), aR), StringEntry(X(T, V), aS), StringEntry(Y(T, V), aC), StringEntry(aa(T, V), aD), StringEntry(Z(T, V), aG), StringEntry(af(T, V), aQ), StringEntry(ag(T, V), aP), StringEntry(ai(T, V), cv), StringEntry(ah(T, V), aT), IntegerEntry(ab(T, V), 0), IntegerEntry(ad(T, V), 0), BooleanEntry(ae(T, V), false), StringEntry(ak(T, V), cw), IntegerEntry(al(T, V), aU), ScriptTransfer(Address(fromBase58String(g)), aZ, r)] ++ co) | |
646 | 590 | } | |
591 | + | else throw("Strict value is not equal to itself.") | |
647 | 592 | } | |
648 | 593 | } | |
649 | 594 | } | |
650 | 595 | ||
651 | 596 | ||
652 | 597 | ||
653 | - | @Callable( | |
654 | - | func updateArtwork ( | |
655 | - | then throw( | |
598 | + | @Callable(aX) | |
599 | + | func updateArtwork (aw,aR,aS,aT,cv,aC,aG,aD,aH,aE,cw,aU,bw) = if (!(G)) | |
600 | + | then throw(H) | |
656 | 601 | else { | |
657 | - | let cD = | |
658 | - | let | |
659 | - | let | |
660 | - | let | |
661 | - | let | |
662 | - | let cE = | |
663 | - | let | |
664 | - | let | |
665 | - | let | |
666 | - | if (( | |
602 | + | let cD = bv(aX, bw) | |
603 | + | let bG = cD._1 | |
604 | + | let T = cD._2 | |
605 | + | let bH = cD._3 | |
606 | + | let bx = cD._4 | |
607 | + | let cE = aN(aE, aH) | |
608 | + | let aP = cE._1 | |
609 | + | let aQ = cE._2 | |
610 | + | let cz = aO(T, aC, aD, aP, aG, aQ, aR, aS, aT, aU) | |
611 | + | if ((cz != "")) | |
667 | 612 | then throw("Something went wrong!") | |
668 | 613 | else { | |
669 | - | let | |
670 | - | if (( | |
614 | + | let cF = b(W(T, aw)) | |
615 | + | if ((cF == "")) | |
671 | 616 | then throw("Entry not found") | |
672 | 617 | else { | |
673 | - | let | |
674 | - | if (( | |
618 | + | let cG = b(ap(T, aw)) | |
619 | + | if ((cG == "ILLEGAL")) | |
675 | 620 | then throw("Cannot update ILLEGAL artwork") | |
676 | - | else if (!( | |
621 | + | else if (!(bd(T, aw))) | |
677 | 622 | then { | |
678 | - | let | |
679 | - | then [ScriptTransfer(Address(fromBase58String( | |
623 | + | let co = if (bx) | |
624 | + | then [ScriptTransfer(Address(fromBase58String(T)), 0, unit)] | |
680 | 625 | else nil | |
681 | - | ([StringEntry( | |
626 | + | ([StringEntry(W(T, aw), aR), StringEntry(X(T, aw), aS), StringEntry(Y(T, aw), aC), StringEntry(aa(T, aw), aD), StringEntry(Z(T, aw), aG), StringEntry(ag(T, aw), aP), StringEntry(af(T, aw), aQ), StringEntry(ah(T, aw), aT), StringEntry(ai(T, aw), cv), StringEntry(ak(T, aw), cw), IntegerEntry(al(T, aw), aU)] ++ co) | |
682 | 627 | } | |
683 | 628 | else throw("Already minted") | |
684 | 629 | } | |
685 | 630 | } | |
686 | 631 | } | |
687 | 632 | ||
688 | 633 | ||
689 | 634 | ||
690 | - | @Callable( | |
691 | - | func flagArtwork ( | |
692 | - | let | |
693 | - | let | |
694 | - | let | |
695 | - | if (containsElement([ | |
696 | - | then if (containsElement(["CONSENT", "", "CHANGE_REQUIRED", "FLAGGED", "ILLEGAL"], | |
697 | - | then [StringEntry( | |
698 | - | else throw(("Unknow status " + | |
635 | + | @Callable(aX) | |
636 | + | func flagArtwork (V,cH,cG,cI) = { | |
637 | + | let cJ = bz(aX) | |
638 | + | let bG = cJ._1 | |
639 | + | let T = cJ._2 | |
640 | + | if (containsElement([y, toString(this)], T)) | |
641 | + | then if (containsElement(["CONSENT", "", "CHANGE_REQUIRED", "FLAGGED", "ILLEGAL"], cG)) | |
642 | + | then [StringEntry(ap(cH, V), cG), StringEntry(aj(cH, V), cI)] | |
643 | + | else throw(("Unknow status " + cG)) | |
699 | 644 | else throw("You are not allowed") | |
700 | 645 | } | |
701 | 646 | ||
702 | 647 | ||
703 | 648 | ||
704 | - | @Callable( | |
705 | - | func deleteArtwork ( | |
706 | - | let | |
707 | - | let | |
708 | - | let | |
709 | - | let | |
710 | - | then | |
711 | - | else | |
712 | - | let | |
713 | - | if (( | |
649 | + | @Callable(aX) | |
650 | + | func deleteArtwork (V,cH) = { | |
651 | + | let cK = bz(aX) | |
652 | + | let bG = cK._1 | |
653 | + | let T = cK._2 | |
654 | + | let be = if (containsElement([y, toString(this)], T)) | |
655 | + | then cH | |
656 | + | else T | |
657 | + | let cF = valueOrErrorMessage(b(W(be, V)), "No art matching for this address") | |
658 | + | if ((cF == "")) | |
714 | 659 | then throw("No art matching for this address") | |
715 | 660 | else { | |
716 | - | let H = b(ar(ba, R)) | |
717 | - | if ((H == "")) | |
718 | - | then throw("No art hash matching for this address") | |
719 | - | else { | |
720 | - | let F = b(Y(ba, R)) | |
721 | - | if ((F == "")) | |
722 | - | then throw("No SIGN ID matching") | |
723 | - | else { | |
724 | - | let cK = [DeleteEntry(Q(ba, R)), DeleteEntry(S(ba, R)), DeleteEntry(T(ba, R)), DeleteEntry(U(ba, R)), DeleteEntry(W(ba, R)), DeleteEntry(V(ba, R)), DeleteEntry(ab(ba, R)), DeleteEntry(ac(ba, R)), DeleteEntry(ae(ba, R)), DeleteEntry(ad(ba, R)), DeleteEntry(X(ba, R)), DeleteEntry(Y(ba, R)), DeleteEntry(Z(ba, R)), DeleteEntry(aa(ba, R)), DeleteEntry(al(ba, R)), DeleteEntry(ai(ba, R)), DeleteEntry(ak(ba, R)), DeleteEntry(at(H)), DeleteEntry(au(ba, F)), DeleteEntry(aw(H, ba)), DeleteEntry(aj(ba, R)), DeleteEntry(af(ba, R)), DeleteEntry(ag(ba, R)), DeleteEntry(ah(ba, R))] | |
725 | - | if (!(aZ(ba, R))) | |
726 | - | then if (!(w)) | |
727 | - | then throw(x) | |
728 | - | else cK | |
729 | - | else if (containsElement([o, toString(this)], P)) | |
730 | - | then cK | |
731 | - | else throw("Art already minted, you cannot delete it") | |
732 | - | } | |
733 | - | } | |
661 | + | let ay = b(av(be, V)) | |
662 | + | let cL = if ((ay == "")) | |
663 | + | then b(ac(be, V)) | |
664 | + | else "" | |
665 | + | let cM = if ((cL == "")) | |
666 | + | then nil | |
667 | + | else [DeleteEntry(az(be, cL))] | |
668 | + | let cN = ([DeleteEntry(U(be, V)), DeleteEntry(W(be, V)), DeleteEntry(X(be, V)), DeleteEntry(Y(be, V)), DeleteEntry(aa(be, V)), DeleteEntry(Z(be, V)), DeleteEntry(af(be, V)), DeleteEntry(ag(be, V)), DeleteEntry(ai(be, V)), DeleteEntry(ah(be, V)), DeleteEntry(ab(be, V)), DeleteEntry(ac(be, V)), DeleteEntry(ad(be, V)), DeleteEntry(ae(be, V)), DeleteEntry(ap(be, V)), DeleteEntry(am(be, V)), DeleteEntry(ao(be, V)), DeleteEntry(ax(ay)), DeleteEntry(an(be, V)), DeleteEntry(aj(be, V)), DeleteEntry(ak(be, V)), DeleteEntry(al(be, V))] ++ cM) | |
669 | + | if (!(bd(be, V))) | |
670 | + | then if (!(G)) | |
671 | + | then throw(H) | |
672 | + | else cN | |
673 | + | else if (containsElement([y, toString(this)], T)) | |
674 | + | then cN | |
675 | + | else throw("Art already minted, you cannot delete it") | |
734 | 676 | } | |
735 | 677 | } | |
736 | 678 | ||
737 | 679 | ||
738 | 680 | ||
739 | - | @Callable( | |
740 | - | func sellArtwork ( | |
741 | - | let | |
742 | - | let | |
743 | - | let | |
744 | - | let | |
745 | - | let | |
746 | - | let | |
747 | - | if (( | |
681 | + | @Callable(aX) | |
682 | + | func sellArtwork (V,bn,cO,bc,bJ,bw) = { | |
683 | + | let cP = bv(aX, bw) | |
684 | + | let bG = cP._1 | |
685 | + | let T = cP._2 | |
686 | + | let bH = cP._3 | |
687 | + | let bx = cP._4 | |
688 | + | let bM = b(W(T, V)) | |
689 | + | if ((bM == "")) | |
748 | 690 | then throw("This art doesn't match your account") | |
749 | 691 | else { | |
750 | - | let | |
751 | - | if (containsElement(["CHANGE_REQUIRED", "FLAGGED", "ILLEGAL"], | |
692 | + | let cG = b(ap(T, V)) | |
693 | + | if (containsElement(["CHANGE_REQUIRED", "FLAGGED", "ILLEGAL"], cG)) | |
752 | 694 | then throw("Flagged artwork") | |
753 | 695 | else { | |
754 | - | let | |
755 | - | if ((0 > | |
696 | + | let cQ = A(("current_bidamount_" + V)) | |
697 | + | if ((0 > bJ)) | |
756 | 698 | then throw("Negative end") | |
757 | - | else if (if (( | |
758 | - | then if (( | |
699 | + | else if (if ((bJ > 0)) | |
700 | + | then if ((cO != 1)) | |
759 | 701 | then true | |
760 | - | else ( | |
702 | + | else (bn != 0) | |
761 | 703 | else false) | |
762 | 704 | then throw("Timed offer only allowed for unique edition and offer only") | |
763 | 705 | else { | |
764 | - | let | |
706 | + | let cR = if ((bJ == 0)) | |
765 | 707 | then 0 | |
766 | 708 | else height | |
767 | - | if (!( | |
709 | + | if (!(bl(bc))) | |
768 | 710 | then throw("Something went wrong!") | |
769 | - | else if (!( | |
711 | + | else if (!(bm(bn))) | |
770 | 712 | then throw("Something went wrong!") | |
771 | 713 | else { | |
772 | - | let | |
773 | - | if (( | |
774 | - | then throw( | |
714 | + | let aV = aL(T) | |
715 | + | if ((aV != "")) | |
716 | + | then throw(aV) | |
775 | 717 | else { | |
776 | - | let | |
777 | - | let | |
778 | - | if (( | |
718 | + | let bO = A(ad(T, V)) | |
719 | + | let bP = A(ab(T, V)) | |
720 | + | if ((cO > 100)) | |
779 | 721 | then throw("100 editions max per artwork") | |
780 | - | else if (if (( | |
781 | - | then ( | |
722 | + | else if (if ((bO != 0)) | |
723 | + | then (bO == bP) | |
782 | 724 | else false) | |
783 | 725 | then throw("Max edition reached.") | |
784 | - | else if (if (( | |
785 | - | then ( | |
726 | + | else if (if ((bO > 0)) | |
727 | + | then (bP != cO) | |
786 | 728 | else false) | |
787 | 729 | then throw("Cannot change maximum issuable anymore") | |
788 | - | else if (if (( | |
789 | - | then ( | |
730 | + | else if (if ((cQ > 0)) | |
731 | + | then (bP != cO) | |
790 | 732 | else false) | |
791 | 733 | then throw("Cannot change maximum issuable with active orders") | |
792 | 734 | else { | |
793 | - | let | |
794 | - | then ( | |
735 | + | let ce = if (if ((bn > 0)) | |
736 | + | then (cO > 0) | |
795 | 737 | else false) | |
796 | 738 | then true | |
797 | 739 | else false | |
798 | - | let | |
799 | - | then [ScriptTransfer(Address(fromBase58String( | |
740 | + | let co = if (bx) | |
741 | + | then [ScriptTransfer(Address(fromBase58String(T)), 0, unit)] | |
800 | 742 | else nil | |
801 | - | ([BooleanEntry( | |
743 | + | ([BooleanEntry(ae(T, V), ce), IntegerEntry(am(T, V), bn), IntegerEntry(ab(T, V), cO), StringEntry(ao(T, V), bc), IntegerEntry(an(T, V), (cR + bJ))] ++ co) | |
802 | 744 | } | |
803 | 745 | } | |
804 | 746 | } | |
805 | 747 | } | |
806 | 748 | } | |
807 | 749 | } | |
808 | 750 | } | |
809 | 751 | ||
810 | 752 | ||
811 | 753 | ||
812 | - | @Callable( | |
813 | - | func buyArtwork ( | |
754 | + | @Callable(aX) | |
755 | + | func buyArtwork (V,bC) = bB(aX, V, bC, "", "", "") | |
814 | 756 | ||
815 | 757 | ||
816 | 758 | ||
817 | - | @Callable( | |
818 | - | func setBid ( | |
819 | - | let | |
820 | - | let | |
821 | - | let | |
822 | - | let | |
823 | - | let | |
824 | - | let | |
825 | - | let | |
826 | - | let | |
759 | + | @Callable(aX) | |
760 | + | func setBid (V,bC) = { | |
761 | + | let cS = bz(aX) | |
762 | + | let bG = cS._1 | |
763 | + | let T = cS._2 | |
764 | + | let bH = cS._3 | |
765 | + | let cT = aW(aX) | |
766 | + | let aY = cT._1 | |
767 | + | let aZ = cT._2 | |
768 | + | let bc = if (!(isDefined(aY.assetId))) | |
827 | 769 | then "WAVES" | |
828 | - | else toBase58String(value( | |
829 | - | let | |
830 | - | if (if (( | |
831 | - | then (height >= | |
770 | + | else toBase58String(value(aY.assetId)) | |
771 | + | let bJ = A(an(bC, V)) | |
772 | + | if (if ((bJ != 0)) | |
773 | + | then (height >= bJ) | |
832 | 774 | else false) | |
833 | 775 | then throw("Sale ended.") | |
834 | 776 | else { | |
835 | - | let | |
836 | - | if (!( | |
777 | + | let cQ = A(("current_bidamount_" + V)) | |
778 | + | if (!(bl(bc))) | |
837 | 779 | then throw("asset not accepted") | |
838 | - | else if (!( | |
780 | + | else if (!(bm(aZ))) | |
839 | 781 | then throw("Wrong min sell") | |
840 | 782 | else { | |
841 | - | let | |
842 | - | let | |
843 | - | if ((0 >= | |
783 | + | let bO = A(ad(bC, V)) | |
784 | + | let bP = A(ab(bC, V)) | |
785 | + | if ((0 >= bP)) | |
844 | 786 | then throw("No max edition set for this artwork") | |
845 | - | else if (( | |
787 | + | else if ((bO >= bP)) | |
846 | 788 | then throw("Sold out, you cannot bid") | |
847 | - | else [StringEntry((((((((("bid_" + | |
789 | + | else [StringEntry((((((((("bid_" + V) + "_") + bC) + "_") + T) + "_") + bG) + "_OPEN"), ((((bc + "_") + toString(aZ)) + "_") + toString(bH))), IntegerEntry(("current_bidamount_" + V), (cQ + 1))] | |
848 | 790 | } | |
849 | 791 | } | |
850 | 792 | } | |
851 | 793 | ||
852 | 794 | ||
853 | 795 | ||
854 | - | @Callable( | |
855 | - | func acceptBid ( | |
796 | + | @Callable(aX) | |
797 | + | func acceptBid (V,bC,bD,bE,bw) = bB(aX, V, bC, bD, bE, bw) | |
856 | 798 | ||
857 | 799 | ||
858 | 800 | ||
859 | - | @Callable( | |
860 | - | func cancelBid ( | |
861 | - | let | |
862 | - | let | |
863 | - | let | |
864 | - | let | |
865 | - | if (if (( | |
866 | - | then ( | |
801 | + | @Callable(aX) | |
802 | + | func cancelBid (V,bC,bD,bE) = { | |
803 | + | let cU = bz(aX) | |
804 | + | let bG = cU._1 | |
805 | + | let T = cU._2 | |
806 | + | let bH = cU._3 | |
807 | + | if (if ((T != bE)) | |
808 | + | then (T != bC) | |
867 | 809 | else false) | |
868 | 810 | then throw("You cannot do this action") | |
869 | 811 | else { | |
870 | - | let | |
871 | - | then | |
872 | - | else | |
873 | - | let | |
874 | - | let | |
875 | - | let | |
876 | - | if (( | |
812 | + | let cV = if ((T == bC)) | |
813 | + | then bE | |
814 | + | else T | |
815 | + | let cQ = A(("current_bidamount_" + V)) | |
816 | + | let bq = ((((((("bid_" + V) + "_") + bC) + "_") + bE) + "_") + bD) | |
817 | + | let br = b((bq + "_OPEN")) | |
818 | + | if ((br == "")) | |
877 | 819 | then throw("Bid not found") | |
878 | 820 | else { | |
879 | - | let | |
880 | - | let | |
881 | - | let | |
882 | - | [DeleteEntry(( | |
821 | + | let bs = split(br, "_") | |
822 | + | let bc = bo(bs[0]) | |
823 | + | let cW = "CANCELED" | |
824 | + | [DeleteEntry((bq + "_OPEN")), StringEntry(((bq + "_") + cW), ((br + "_") + toString(bH))), IntegerEntry(("current_bidamount_" + V), (cQ - 1)), ScriptTransfer(Address(fromBase58String(cV)), parseIntValue(bs[1]), bc)] | |
883 | 825 | } | |
884 | 826 | } | |
885 | 827 | } | |
886 | 828 | ||
887 | 829 | ||
888 | - | @Verifier( | |
889 | - | func | |
890 | - | let | |
891 | - | if ($isInstanceOf( | |
830 | + | @Verifier(cX) | |
831 | + | func cY () = { | |
832 | + | let bf = cX | |
833 | + | if ($isInstanceOf(bf, "InvokeScriptTransaction")) | |
892 | 834 | then { | |
893 | - | let | |
894 | - | if (if (if (if (( | |
895 | - | then ( | |
835 | + | let cZ = bf | |
836 | + | if (if (if (if ((cZ.function == "addArtwork")) | |
837 | + | then (cZ.dApp == this) | |
896 | 838 | else false) | |
897 | - | then ( | |
839 | + | then (cZ.fee == 500000) | |
898 | 840 | else false) | |
899 | - | then ( | |
841 | + | then (cZ.feeAssetId == unit) | |
900 | 842 | else false) | |
901 | - | then sigVerify( | |
902 | - | else if (if (if (if (( | |
903 | - | then ( | |
843 | + | then sigVerify(cX.bodyBytes, cX.proofs[0], fromBase58String(cq(cZ.args[11]))) | |
844 | + | else if (if (if (if ((cZ.function == "updateArtwork")) | |
845 | + | then (cZ.dApp == this) | |
904 | 846 | else false) | |
905 | - | then ( | |
847 | + | then (cZ.fee == 500000) | |
906 | 848 | else false) | |
907 | - | then ( | |
849 | + | then (cZ.feeAssetId == unit) | |
908 | 850 | else false) | |
909 | - | then sigVerify( | |
910 | - | else if (if (if (if (( | |
911 | - | then ( | |
851 | + | then sigVerify(cX.bodyBytes, cX.proofs[0], fromBase58String(cq(cZ.args[12]))) | |
852 | + | else if (if (if (if ((cZ.function == "sellArtwork")) | |
853 | + | then (cZ.dApp == this) | |
912 | 854 | else false) | |
913 | - | then ( | |
855 | + | then (cZ.fee == 500000) | |
914 | 856 | else false) | |
915 | - | then ( | |
857 | + | then (cZ.feeAssetId == unit) | |
916 | 858 | else false) | |
917 | - | then sigVerify( | |
918 | - | else if (if (if (if (( | |
919 | - | then ( | |
859 | + | then sigVerify(cX.bodyBytes, cX.proofs[0], fromBase58String(cq(cZ.args[5]))) | |
860 | + | else if (if (if (if ((cZ.function == "acceptBid")) | |
861 | + | then (cZ.dApp == this) | |
920 | 862 | else false) | |
921 | - | then ( | |
863 | + | then (cZ.fee == 500000) | |
922 | 864 | else false) | |
923 | - | then ( | |
865 | + | then (cZ.feeAssetId == unit) | |
924 | 866 | else false) | |
925 | - | then sigVerify_128Kb( | |
926 | - | else sigVerify( | |
867 | + | then sigVerify_128Kb(cX.bodyBytes, cX.proofs[0], fromBase58String(cq(cZ.args[4]))) | |
868 | + | else sigVerify(cX.bodyBytes, cX.proofs[0], cX.senderPublicKey) | |
927 | 869 | } | |
928 | - | else sigVerify( | |
870 | + | else sigVerify(cX.bodyBytes, cX.proofs[0], cX.senderPublicKey) | |
929 | 871 | } | |
930 | 872 |
github/deemru/w8io/169f3d6 313.13 ms ◑