tx · 45Bt8N9suyfqKfoLjzTtKbPAHvzkQ3u9FUH9MKos9dZH
3NBwZbvD45CscLGF78qTaDRBZ7mDBHt3Yib: -0.01400000 Waves
2022.09.15 05:16 [2229602] smart account 3NBwZbvD45CscLGF78qTaDRBZ7mDBHt3Yib > SELF 0.00000000 Waves
{
"type": 13,
"id": "45Bt8N9suyfqKfoLjzTtKbPAHvzkQ3u9FUH9MKos9dZH",
"fee": 1400000,
"feeAssetId": null,
"timestamp": 1663208230453,
"version": 2,
"chainId": 84,
"sender": "3NBwZbvD45CscLGF78qTaDRBZ7mDBHt3Yib",
"senderPublicKey": "3q3N8Kv49DbzNHyTB4A87UYz2DdquXCgP3GNCcD9Zj66",
"proofs": [
"24rHcxmtdW1E86nRyJgb1mCSzqX9wUidfSgebuCtATE5h18mHXq3vkCscHnXCo1KTGwh7M3pvWWKYHkPqghvVNCj"
],
"script": "base64:BgJGCAISDQoLCAgICAgBCAgBAQQSBAoCCAgSBAoCCAESBAoCAQESAwoBBBIECgIICBIFCgMICAgSBAoCCAgSBAoCBAgSAwoBCD0AB3ZlcnNpb24CAzEuMAALQ09ORl9JTklUX0sCC2NvbmZpZ19pbml0AAtDT05GX0FNSU5fSwIMY29uZmlnX2FkbWluAA1DT05GX09SQUNMRV9LAg1jb25maWdfb3JhY2xlABNDT05GX0FSVFdPUktfREFQUF9LAhNjb25maWdfYXJ0d29ya19kYXBwABFDT05GX1VTRVJTX0RBUFBfSwIRY29uZmlnX3VzZXJzX2RhcHAAEENPTkZfRkVFX0FTU0VUX0sCEGNvbmZpZ19mZWVfYXNzZXQAEUNPTkZfRkVFX0FNT1VOVF9LAhFjb25maWdfZmVlX2Ftb3VudAAVQ09ORl9TV09QX1NJR05fREFQUF9LAhVjb25maWdfc3dvcF9zaWduX2RhcHAAFENPTkZfU1dPUF9FVEhfREFQUF9LAhRjb25maWdfc3dvcF9ldGhfZGFwcAAfQ09ORl9DT05GSVJNQVRJT05TX0ZST01fV0FWRVNfSwIfY29uZ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EBIQEFBmlzSW5pdAkAAgECDmRBcHAgbm90IHJlYWR5AwkBCW93bmVyT25seQEFAWkJAMwIAgkBDEJvb2xlYW5FbnRyeQIFDWRhcHBSdW5uaW5nX0sFBmlzTGl2ZQkAzAgCCQELU3RyaW5nRW50cnkCBRBtYWludGVuYW5jZU1TR19LBQdtZXNzYWdlBQNuaWwJAAIBAiJZb3UgYXJlIG5vdCBhbGxvd2VkIHRvIGNoYW5nZSB0aGlzAWkBC2RlbGV0ZUVudHJ5AQVlbnRyeQMJAQlvd25lck9ubHkBBQFpCQDMCAIJAQtEZWxldGVFbnRyeQEFBWVudHJ5BQNuaWwJAAIBAgJubwC6iG45",
"height": 2229602,
"applicationStatus": "succeeded",
"spentComplexity": 0
}
View: original | compacted
Prev: 2MBpJFiBayanqWMKJAbd5PozsxAJA2kqGJ7gqh2VrBNh
Next: DALUtW1dMsRCquyWm8svBxVim3jk8AkrT2SUyGswHwZM
Diff:
Old | New | | Differences |
---|
25 | 25 | | |
---|
26 | 26 | | let l = "config_confirmations_from_eth" |
---|
27 | 27 | | |
---|
28 | | - | let m = "conf_dapp_is_running" |
---|
| 28 | + | let m = "config_autoswap" |
---|
29 | 29 | | |
---|
30 | | - | let n = "conf_maintenance_msg" |
---|
| 30 | + | let n = "conf_dapp_is_running" |
---|
31 | 31 | | |
---|
32 | | - | let o = valueOrElse(getBoolean(this, m), true) |
---|
| 32 | + | let o = "conf_maintenance_msg" |
---|
33 | 33 | | |
---|
34 | | - | let p = valueOrElse(getString(this, n), "") |
---|
| 34 | + | let p = valueOrElse(getBoolean(this, n), true) |
---|
35 | 35 | | |
---|
36 | | - | let q = "LOCKED" |
---|
| 36 | + | let q = valueOrElse(getString(this, o), "") |
---|
37 | 37 | | |
---|
38 | | - | let r = "UNLOCKED" |
---|
| 38 | + | let r = "LOCKED" |
---|
39 | 39 | | |
---|
40 | | - | let s = "PENDING" |
---|
| 40 | + | let s = "UNLOCKED" |
---|
41 | 41 | | |
---|
42 | | - | let t = "CLOSED" |
---|
| 42 | + | let t = "PENDING" |
---|
43 | 43 | | |
---|
44 | | - | let u = "REGISTERED" |
---|
| 44 | + | let u = "CLOSED" |
---|
45 | 45 | | |
---|
46 | | - | let v = "VERIFIED" |
---|
| 46 | + | let v = "REGISTERED" |
---|
47 | 47 | | |
---|
48 | | - | let w = "FLAGGED" |
---|
| 48 | + | let w = "VERIFIED" |
---|
49 | 49 | | |
---|
50 | | - | let x = "ILLEGAL" |
---|
| 50 | + | let x = "FLAGGED" |
---|
51 | 51 | | |
---|
52 | | - | let y = "CHANGE_REQUIRED" |
---|
| 52 | + | let y = "ILLEGAL" |
---|
53 | 53 | | |
---|
54 | | - | let z = ["ETH"] |
---|
| 54 | + | let z = "CHANGE_REQUIRED" |
---|
55 | 55 | | |
---|
56 | | - | func A (B) = (("nft_" + B) + "_status") |
---|
| 56 | + | let A = ["ETH"] |
---|
| 57 | + | |
---|
| 58 | + | func B (C) = (("nft_" + C) + "_status") |
---|
57 | 59 | | |
---|
58 | 60 | | |
---|
59 | | - | func C (B,D,E) = ((((("transfer_" + B) + "_") + D) + "_") + E) |
---|
| 61 | + | func D (C,E,F) = ((((("transfer_" + C) + "_") + E) + "_") + F) |
---|
60 | 62 | | |
---|
61 | 63 | | |
---|
62 | | - | let F = "cost_non_minted" |
---|
| 64 | + | let G = "cost_non_minted" |
---|
63 | 65 | | |
---|
64 | | - | let G = "cost_minted" |
---|
| 66 | + | let H = "cost_minted" |
---|
65 | 67 | | |
---|
66 | | - | func H (I) = valueOrElse(getString(this, I), "") |
---|
| 68 | + | func I (J) = valueOrElse(getString(this, J), "") |
---|
67 | 69 | | |
---|
68 | 70 | | |
---|
69 | | - | func J (I) = valueOrElse(getInteger(this, I), 0) |
---|
| 71 | + | func K (J) = valueOrElse(getInteger(this, J), 0) |
---|
70 | 72 | | |
---|
71 | 73 | | |
---|
72 | | - | func K (I) = valueOrElse(getBoolean(this, I), false) |
---|
| 74 | + | func L (J) = valueOrElse(getBoolean(this, J), false) |
---|
73 | 75 | | |
---|
74 | 76 | | |
---|
75 | | - | let L = value(addressFromStringValue(H(c))) |
---|
| 77 | + | let M = value(addressFromStringValue(I(c))) |
---|
76 | 78 | | |
---|
77 | | - | let M = value(addressFromString(H(e))) |
---|
| 79 | + | let N = value(addressFromString(I(e))) |
---|
78 | 80 | | |
---|
79 | | - | let N = value(addressFromString(H(f))) |
---|
| 81 | + | let O = value(addressFromString(I(f))) |
---|
80 | 82 | | |
---|
81 | | - | let O = value(addressFromString(H(d))) |
---|
| 83 | + | let P = value(addressFromString(I(d))) |
---|
82 | 84 | | |
---|
83 | | - | let P = H(g) |
---|
| 85 | + | let Q = valueOrElse(L(m), false) |
---|
84 | 86 | | |
---|
85 | | - | let Q = J(h) |
---|
| 87 | + | let R = I(g) |
---|
86 | 88 | | |
---|
87 | | - | func R (I) = valueOrElse(getString(N, I), "") |
---|
| 89 | + | let S = K(h) |
---|
| 90 | + | |
---|
| 91 | + | func T (J) = valueOrElse(getString(O, J), "") |
---|
88 | 92 | | |
---|
89 | 93 | | |
---|
90 | | - | func S (I) = valueOrElse(getString(M, I), "") |
---|
| 94 | + | func U (J) = valueOrElse(getString(N, J), "") |
---|
91 | 95 | | |
---|
92 | 96 | | |
---|
93 | | - | func T (I) = valueOrErrorMessage(getInteger(O, I), "Integer undefined in oracle") |
---|
| 97 | + | func V (J) = valueOrErrorMessage(getInteger(P, J), "Integer undefined in oracle") |
---|
94 | 98 | | |
---|
95 | 99 | | |
---|
96 | | - | func U (V) = if (if (if ((V.quantity == 1)) |
---|
97 | | - | then (V.decimals == 0) |
---|
| 100 | + | func W (X) = if (if (if ((X.quantity == 1)) |
---|
| 101 | + | then (X.decimals == 0) |
---|
98 | 102 | | else false) |
---|
99 | | - | then (V.reissuable == false) |
---|
| 103 | + | then (X.reissuable == false) |
---|
100 | 104 | | else false) |
---|
101 | | - | then (V.issuer == M) |
---|
| 105 | + | then (X.issuer == N) |
---|
102 | 106 | | else false |
---|
103 | 107 | | |
---|
104 | 108 | | |
---|
105 | | - | func W (X) = { |
---|
106 | | - | let V = value(assetInfo(X)) |
---|
107 | | - | U(V) |
---|
| 109 | + | func Y (Z) = { |
---|
| 110 | + | let X = value(assetInfo(Z)) |
---|
| 111 | + | W(X) |
---|
108 | 112 | | } |
---|
109 | 113 | | |
---|
110 | 114 | | |
---|
111 | | - | func Y (Z) = if ((size(Z.payments) != 2)) |
---|
| 115 | + | func aa (ab) = if ((size(ab.payments) != 2)) |
---|
112 | 116 | | then throw("Need to attach 2 payments") |
---|
113 | 117 | | else { |
---|
114 | | - | let aa = value(Z.payments[0]) |
---|
115 | | - | let ab = value(aa.amount) |
---|
116 | | - | let ac = value(Z.payments[1]) |
---|
| 118 | + | let ac = value(ab.payments[0]) |
---|
117 | 119 | | let ad = value(ac.amount) |
---|
118 | | - | $Tuple4(aa, ab, ac, ad) |
---|
| 120 | + | let ae = value(ab.payments[1]) |
---|
| 121 | + | let af = value(ae.amount) |
---|
| 122 | + | $Tuple4(ac, ad, ae, af) |
---|
119 | 123 | | } |
---|
120 | 124 | | |
---|
121 | 125 | | |
---|
122 | | - | let ae = valueOrElse(K(b), false) |
---|
| 126 | + | let ag = valueOrElse(L(b), false) |
---|
123 | 127 | | |
---|
124 | | - | func af (Z) = { |
---|
125 | | - | let E = toString(Z.caller) |
---|
126 | | - | let X = toBase58String(Z.transactionId) |
---|
127 | | - | let ag = if (ae) |
---|
128 | | - | then [toString(L), toString(this)] |
---|
| 128 | + | func ah (ab) = { |
---|
| 129 | + | let F = toString(ab.caller) |
---|
| 130 | + | let Z = toBase58String(ab.transactionId) |
---|
| 131 | + | let ai = if (ag) |
---|
| 132 | + | then [toString(M), toString(this)] |
---|
129 | 133 | | else [toString(this)] |
---|
130 | | - | containsElement(ag, E) |
---|
| 134 | + | containsElement(ai, F) |
---|
131 | 135 | | } |
---|
132 | 136 | | |
---|
133 | 137 | | |
---|
134 | | - | func ah (Z) = if (!(o)) |
---|
135 | | - | then throw(p) |
---|
136 | | - | else $Tuple3(toBase58String(Z.transactionId), toBase58String(Z.caller.bytes), lastBlock.timestamp) |
---|
| 138 | + | func aj (ab) = if (!(p)) |
---|
| 139 | + | then throw(q) |
---|
| 140 | + | else $Tuple3(toBase58String(ab.transactionId), toBase58String(ab.caller.bytes), lastBlock.timestamp) |
---|
137 | 141 | | |
---|
138 | 142 | | |
---|
139 | | - | func ai (aj) = { |
---|
140 | | - | let ak = S(("nft_" + aj)) |
---|
141 | | - | let al = split(ak, "_")[6] |
---|
142 | | - | let am = split(ak, "_")[5] |
---|
143 | | - | $Tuple2(al, am) |
---|
| 143 | + | func ak (al) = { |
---|
| 144 | + | let am = U(("nft_" + al)) |
---|
| 145 | + | let an = split(am, "_")[6] |
---|
| 146 | + | let ao = split(am, "_")[5] |
---|
| 147 | + | $Tuple2(an, ao) |
---|
144 | 148 | | } |
---|
145 | 149 | | |
---|
146 | 150 | | |
---|
147 | | - | func an (ao) = R(("user_ERC20_" + ao)) |
---|
| 151 | + | func ap (aq) = T(("user_ERC20_" + aq)) |
---|
148 | 152 | | |
---|
149 | 153 | | |
---|
150 | | - | func ap (ao) = R(("user_status_" + ao)) |
---|
| 154 | + | func ar (aq) = T(("user_status_" + aq)) |
---|
151 | 155 | | |
---|
152 | 156 | | |
---|
153 | | - | func aq (am,ao) = S(((("art_flag_" + am) + "_") + ao)) |
---|
| 157 | + | func as (ao,aq) = U(((("art_flag_" + ao) + "_") + aq)) |
---|
154 | 158 | | |
---|
155 | 159 | | |
---|
156 | | - | func ar (as) = if ((as == u)) |
---|
| 160 | + | func at (au) = if ((au == v)) |
---|
157 | 161 | | then true |
---|
158 | | - | else (as == v) |
---|
| 162 | + | else (au == w) |
---|
159 | 163 | | |
---|
160 | 164 | | |
---|
161 | | - | func at (as) = if (if ((as != w)) |
---|
162 | | - | then (as != x) |
---|
| 165 | + | func av (au) = if (if ((au != x)) |
---|
| 166 | + | then (au != y) |
---|
163 | 167 | | else false) |
---|
164 | | - | then (as != y) |
---|
| 168 | + | then (au != z) |
---|
165 | 169 | | else false |
---|
166 | 170 | | |
---|
167 | 171 | | |
---|
168 | | - | func au (ao) = if ((size(ao) == 42)) |
---|
169 | | - | then (take(ao, 2) == "0x") |
---|
| 172 | + | func aw (aq) = if ((size(aq) == 42)) |
---|
| 173 | + | then (take(aq, 2) == "0x") |
---|
170 | 174 | | else false |
---|
171 | 175 | | |
---|
172 | 176 | | |
---|
173 | | - | func av (aw,ax) = [StringEntry(i, aw), StringEntry(j, ax)] |
---|
| 177 | + | func ax (ay,az) = [StringEntry(i, ay), StringEntry(j, az)] |
---|
174 | 178 | | |
---|
175 | 179 | | |
---|
176 | | - | func ay (az,aA) = { |
---|
177 | | - | let V = assetInfo(fromBase58String(az)) |
---|
178 | | - | let aB = value(V).decimals |
---|
179 | | - | let aC = pow(aA, 0, 10, 1, aB, HALFUP) |
---|
180 | | - | [StringEntry(g, az), IntegerEntry(h, aC)] |
---|
| 180 | + | func aA (aB,aC) = { |
---|
| 181 | + | let X = assetInfo(fromBase58String(aB)) |
---|
| 182 | + | let aD = value(X).decimals |
---|
| 183 | + | let aE = pow(aC, 0, 10, 1, aD, HALFUP) |
---|
| 184 | + | [StringEntry(g, aB), IntegerEntry(h, aE)] |
---|
181 | 185 | | } |
---|
182 | 186 | | |
---|
183 | 187 | | |
---|
184 | | - | func aD (aE,aF) = [IntegerEntry(k, aE), IntegerEntry(l, aF)] |
---|
| 188 | + | func aF (aG,aH) = [IntegerEntry(k, aG), IntegerEntry(l, aH)] |
---|
185 | 189 | | |
---|
186 | 190 | | |
---|
187 | | - | @Callable(Z) |
---|
188 | | - | func init (aG,O,M,N,az,aA,aw,ax,aE,aF) = if (af(Z)) |
---|
| 191 | + | func aI (Q) = [BooleanEntry(m, Q)] |
---|
| 192 | + | |
---|
| 193 | + | |
---|
| 194 | + | @Callable(ab) |
---|
| 195 | + | func init (aJ,P,N,O,aB,aC,ay,az,aG,aH,Q) = if (ah(ab)) |
---|
189 | 196 | | then { |
---|
190 | | - | let aH = av(aw, ax) |
---|
191 | | - | let aI = ay(az, aA) |
---|
192 | | - | let aJ = aD(aE, aF) |
---|
193 | | - | ((([StringEntry(c, aG), StringEntry(d, O), StringEntry(e, M), StringEntry(f, N), BooleanEntry(b, true)] ++ aH) ++ aI) ++ aJ) |
---|
| 197 | + | let aK = ax(ay, az) |
---|
| 198 | + | let aL = aA(aB, aC) |
---|
| 199 | + | let aM = aF(aG, aH) |
---|
| 200 | + | let aN = aI(Q) |
---|
| 201 | + | (((([StringEntry(c, aJ), StringEntry(d, P), StringEntry(e, N), StringEntry(f, O), BooleanEntry(b, true)] ++ aK) ++ aL) ++ aM) ++ aN) |
---|
194 | 202 | | } |
---|
195 | 203 | | else throw("Not allowed") |
---|
196 | 204 | | |
---|
197 | 205 | | |
---|
198 | 206 | | |
---|
199 | | - | @Callable(Z) |
---|
200 | | - | func setSwopDapps (aw,ax) = if (af(Z)) |
---|
201 | | - | then av(aw, ax) |
---|
| 207 | + | @Callable(ab) |
---|
| 208 | + | func setSwopDapps (ay,az) = if (ah(ab)) |
---|
| 209 | + | then ax(ay, az) |
---|
202 | 210 | | else throw("Not allowed") |
---|
203 | 211 | | |
---|
204 | 212 | | |
---|
205 | 213 | | |
---|
206 | | - | @Callable(Z) |
---|
207 | | - | func setFee (az,aA) = if (af(Z)) |
---|
208 | | - | then ay(az, aA) |
---|
| 214 | + | @Callable(ab) |
---|
| 215 | + | func setFee (aB,aC) = if (ah(ab)) |
---|
| 216 | + | then aA(aB, aC) |
---|
209 | 217 | | else throw("Not allowed") |
---|
210 | 218 | | |
---|
211 | 219 | | |
---|
212 | 220 | | |
---|
213 | | - | @Callable(Z) |
---|
214 | | - | func setConfirmations (aE,aF) = if (af(Z)) |
---|
215 | | - | then aD(aE, aF) |
---|
| 221 | + | @Callable(ab) |
---|
| 222 | + | func setConfirmations (aG,aH) = if (ah(ab)) |
---|
| 223 | + | then aF(aG, aH) |
---|
216 | 224 | | else throw("Not allowed") |
---|
217 | 225 | | |
---|
218 | 226 | | |
---|
219 | 227 | | |
---|
220 | | - | @Callable(Z) |
---|
221 | | - | func lock (aK,aL) = if (!(ae)) |
---|
| 228 | + | @Callable(ab) |
---|
| 229 | + | func setAutoswap (Q) = if (ah(ab)) |
---|
| 230 | + | then aI(Q) |
---|
| 231 | + | else throw("Not allowed") |
---|
| 232 | + | |
---|
| 233 | + | |
---|
| 234 | + | |
---|
| 235 | + | @Callable(ab) |
---|
| 236 | + | func lock (aO,aP) = if (!(ag)) |
---|
222 | 237 | | then throw("dApp not ready") |
---|
223 | | - | else if (!(containsElement(z, aL))) |
---|
| 238 | + | else if (!(containsElement(A, aP))) |
---|
224 | 239 | | then throw("Network not supported") |
---|
225 | | - | else if (!(au(aK))) |
---|
| 240 | + | else if (!(aw(aO))) |
---|
226 | 241 | | then throw("Wrong recipient address") |
---|
227 | 242 | | else { |
---|
228 | | - | let aM = ah(Z) |
---|
229 | | - | let X = aM._1 |
---|
230 | | - | let E = aM._2 |
---|
231 | | - | let aN = aM._3 |
---|
232 | | - | let aO = Y(Z) |
---|
233 | | - | let aa = aO._1 |
---|
234 | | - | let ab = aO._2 |
---|
235 | | - | let ac = aO._3 |
---|
236 | | - | let ad = aO._4 |
---|
237 | | - | if ((ab != 1)) |
---|
| 243 | + | let aQ = aj(ab) |
---|
| 244 | + | let Z = aQ._1 |
---|
| 245 | + | let F = aQ._2 |
---|
| 246 | + | let aR = aQ._3 |
---|
| 247 | + | let aS = aa(ab) |
---|
| 248 | + | let ac = aS._1 |
---|
| 249 | + | let ad = aS._2 |
---|
| 250 | + | let ae = aS._3 |
---|
| 251 | + | let af = aS._4 |
---|
| 252 | + | if ((ad != 1)) |
---|
238 | 253 | | then throw("No NFT attached") |
---|
239 | 254 | | else { |
---|
240 | | - | let B = if (if (isDefined(aa.assetId)) |
---|
241 | | - | then W(value(aa.assetId)) |
---|
| 255 | + | let C = if (if (isDefined(ac.assetId)) |
---|
| 256 | + | then Y(value(ac.assetId)) |
---|
242 | 257 | | else false) |
---|
243 | | - | then toBase58String(value(aa.assetId)) |
---|
| 258 | + | then toBase58String(value(ac.assetId)) |
---|
244 | 259 | | else throw("Only SIGN Art NFT accepted.") |
---|
245 | | - | let aP = ai(B) |
---|
246 | | - | let al = aP._1 |
---|
247 | | - | let am = aP._2 |
---|
248 | | - | if (!(ar(ap(al)))) |
---|
249 | | - | then throw(("Creator status is :" + ap(al))) |
---|
250 | | - | else if (!(at(aq(am, al)))) |
---|
251 | | - | then throw(("Artwork status is :" + aq(am, al))) |
---|
| 260 | + | let aT = ak(C) |
---|
| 261 | + | let an = aT._1 |
---|
| 262 | + | let ao = aT._2 |
---|
| 263 | + | if (!(at(ar(an)))) |
---|
| 264 | + | then throw(("Creator status is :" + ar(an))) |
---|
| 265 | + | else if (!(av(as(ao, an)))) |
---|
| 266 | + | then throw(("Artwork status is :" + as(ao, an))) |
---|
252 | 267 | | else { |
---|
253 | | - | let aQ = an(al) |
---|
254 | | - | if ((size(aQ) == 0)) |
---|
| 268 | + | let aU = ap(an) |
---|
| 269 | + | if ((size(aU) == 0)) |
---|
255 | 270 | | then throw("This artist didn't allow crosschain transfer") |
---|
256 | 271 | | else { |
---|
257 | | - | let aR = H(A(B)) |
---|
258 | | - | if (if ((aR == q)) |
---|
| 272 | + | let aV = I(B(C)) |
---|
| 273 | + | if (if ((aV == r)) |
---|
259 | 274 | | then true |
---|
260 | | - | else (aR == s)) |
---|
| 275 | + | else (aV == t)) |
---|
261 | 276 | | then throw("NFT already locked") |
---|
262 | 277 | | else { |
---|
263 | | - | let aS = T(F) |
---|
264 | | - | let aT = T(G) |
---|
265 | | - | let aU = if ((aR == r)) |
---|
| 278 | + | let aW = V(G) |
---|
| 279 | + | let aX = V(H) |
---|
| 280 | + | let aY = if ((aV == s)) |
---|
266 | 281 | | then true |
---|
267 | 282 | | else false |
---|
268 | | - | if (if (!(isDefined(ac.assetId))) |
---|
| 283 | + | if (if (!(isDefined(ae.assetId))) |
---|
269 | 284 | | then true |
---|
270 | | - | else (toBase58String(value(ac.assetId)) != P)) |
---|
| 285 | + | else (toBase58String(value(ae.assetId)) != R)) |
---|
271 | 286 | | then throw("Wrong payment asset") |
---|
272 | | - | else if (if (aU) |
---|
273 | | - | then (ad > (aT + Q)) |
---|
| 287 | + | else if (if (aY) |
---|
| 288 | + | then (af > (aX + S)) |
---|
274 | 289 | | else false) |
---|
275 | 290 | | then throw("Wrong payment amount to unlock") |
---|
276 | | - | else if (if (!(aU)) |
---|
277 | | - | then (ad > (aS + Q)) |
---|
| 291 | + | else if (if (!(aY)) |
---|
| 292 | + | then (af > (aW + S)) |
---|
278 | 293 | | else false) |
---|
279 | 294 | | then throw("Wrong payment amount to mint and unlock") |
---|
280 | 295 | | else { |
---|
281 | | - | let aV = if (aU) |
---|
282 | | - | then aT |
---|
283 | | - | else aS |
---|
284 | | - | let aW = invoke(addressFromStringValue(H(i)), "exchange", [1], [AttachedPayment(fromBase58String(P), Q)]) |
---|
285 | | - | if ((aW == aW)) |
---|
| 296 | + | let aZ = if (aY) |
---|
| 297 | + | then aX |
---|
| 298 | + | else aW |
---|
| 299 | + | let ba = if (Q) |
---|
| 300 | + | then invoke(addressFromStringValue(I(i)), "exchange", [1], [AttachedPayment(fromBase58String(R), S)]) |
---|
| 301 | + | else unit |
---|
| 302 | + | if ((ba == ba)) |
---|
286 | 303 | | then { |
---|
287 | | - | let aX = invoke(addressFromStringValue(H(j)), "exchange", [1], [AttachedPayment(fromBase58String(P), aV)]) |
---|
288 | | - | if ((aX == aX)) |
---|
289 | | - | then [StringEntry(A(B), s), StringEntry(((C(B, X, E) + "_") + s), ((((((((((((aK + "_") + aL) + "_") + E) + "_") + X) + "_") + value(assetInfo(value(aa.assetId))).name) + "_") + toString(aN)) + "_") + toString(height)))] |
---|
| 304 | + | let bb = if (Q) |
---|
| 305 | + | then invoke(addressFromStringValue(I(j)), "exchange", [1], [AttachedPayment(fromBase58String(R), aZ)]) |
---|
| 306 | + | else unit |
---|
| 307 | + | if ((bb == bb)) |
---|
| 308 | + | then [StringEntry(B(C), t), StringEntry(((D(C, Z, F) + "_") + t), ((((((((((((aO + "_") + aP) + "_") + F) + "_") + Z) + "_") + value(assetInfo(value(ac.assetId))).name) + "_") + toString(aR)) + "_") + toString(height)))] |
---|
290 | 309 | | else throw("Strict value is not equal to itself.") |
---|
291 | 310 | | } |
---|
292 | 311 | | else throw("Strict value is not equal to itself.") |
---|
|
299 | 318 | | |
---|
300 | 319 | | |
---|
301 | 320 | | |
---|
302 | | - | @Callable(Z) |
---|
303 | | - | func confirmLock (B,aY,E) = if (!(ae)) |
---|
| 321 | + | @Callable(ab) |
---|
| 322 | + | func confirmLock (C,bc,F) = if (!(ag)) |
---|
304 | 323 | | then throw("dApp not ready") |
---|
305 | | - | else if (af(Z)) |
---|
| 324 | + | else if (ah(ab)) |
---|
306 | 325 | | then { |
---|
307 | | - | let aR = H(A(B)) |
---|
308 | | - | if ((aR != s)) |
---|
| 326 | + | let aV = I(B(C)) |
---|
| 327 | + | if ((aV != t)) |
---|
309 | 328 | | then throw("NFT not pending") |
---|
310 | 329 | | else { |
---|
311 | | - | let aZ = H(((C(B, aY, E) + "_") + s)) |
---|
312 | | - | let ba = ((C(B, aY, E) + "_") + t) |
---|
313 | | - | [DeleteEntry(((C(B, aY, E) + "_") + s)), StringEntry(ba, aZ), StringEntry(A(B), q)] |
---|
| 330 | + | let bd = I(((D(C, bc, F) + "_") + t)) |
---|
| 331 | + | let be = ((D(C, bc, F) + "_") + u) |
---|
| 332 | + | [DeleteEntry(((D(C, bc, F) + "_") + t)), StringEntry(be, bd), StringEntry(B(C), r)] |
---|
314 | 333 | | } |
---|
315 | 334 | | } |
---|
316 | 335 | | else throw("Not allowed") |
---|
317 | 336 | | |
---|
318 | 337 | | |
---|
319 | 338 | | |
---|
320 | | - | @Callable(Z) |
---|
321 | | - | func unlock (aK,B) = if (!(ae)) |
---|
| 339 | + | @Callable(ab) |
---|
| 340 | + | func unlock (aO,C) = if (!(ag)) |
---|
322 | 341 | | then throw("dApp not ready") |
---|
323 | | - | else if (af(Z)) |
---|
| 342 | + | else if (ah(ab)) |
---|
324 | 343 | | then { |
---|
325 | | - | let aR = H(A(B)) |
---|
326 | | - | if ((aR != q)) |
---|
| 344 | + | let aV = I(B(C)) |
---|
| 345 | + | if ((aV != r)) |
---|
327 | 346 | | then throw("NFT not locked, finalize first if pending") |
---|
328 | | - | else [StringEntry(A(B), r), ScriptTransfer(Address(fromBase58String(aK)), 1, fromBase58String(B))] |
---|
| 347 | + | else [StringEntry(B(C), s), ScriptTransfer(Address(fromBase58String(aO)), 1, fromBase58String(C))] |
---|
329 | 348 | | } |
---|
330 | 349 | | else throw("Not allowed") |
---|
331 | 350 | | |
---|
332 | 351 | | |
---|
333 | 352 | | |
---|
334 | | - | @Callable(Z) |
---|
335 | | - | func appRunning (bb,bc) = if (!(ae)) |
---|
| 353 | + | @Callable(ab) |
---|
| 354 | + | func appRunning (bf,bg) = if (!(ag)) |
---|
336 | 355 | | then throw("dApp not ready") |
---|
337 | | - | else if (af(Z)) |
---|
338 | | - | then [BooleanEntry(m, bb), StringEntry(n, bc)] |
---|
| 356 | + | else if (ah(ab)) |
---|
| 357 | + | then [BooleanEntry(n, bf), StringEntry(o, bg)] |
---|
339 | 358 | | else throw("You are not allowed to change this") |
---|
340 | 359 | | |
---|
341 | 360 | | |
---|
342 | 361 | | |
---|
343 | | - | @Callable(Z) |
---|
344 | | - | func deleteEntry (bd) = if (af(Z)) |
---|
345 | | - | then [DeleteEntry(bd)] |
---|
| 362 | + | @Callable(ab) |
---|
| 363 | + | func deleteEntry (bh) = if (ah(ab)) |
---|
| 364 | + | then [DeleteEntry(bh)] |
---|
346 | 365 | | else throw("no") |
---|
347 | 366 | | |
---|
348 | 367 | | |
---|
Full:
Old | New | | Differences |
---|
1 | 1 | | {-# STDLIB_VERSION 6 #-} |
---|
2 | 2 | | {-# SCRIPT_TYPE ACCOUNT #-} |
---|
3 | 3 | | {-# CONTENT_TYPE DAPP #-} |
---|
4 | 4 | | let a = "1.0" |
---|
5 | 5 | | |
---|
6 | 6 | | let b = "config_init" |
---|
7 | 7 | | |
---|
8 | 8 | | let c = "config_admin" |
---|
9 | 9 | | |
---|
10 | 10 | | let d = "config_oracle" |
---|
11 | 11 | | |
---|
12 | 12 | | let e = "config_artwork_dapp" |
---|
13 | 13 | | |
---|
14 | 14 | | let f = "config_users_dapp" |
---|
15 | 15 | | |
---|
16 | 16 | | let g = "config_fee_asset" |
---|
17 | 17 | | |
---|
18 | 18 | | let h = "config_fee_amount" |
---|
19 | 19 | | |
---|
20 | 20 | | let i = "config_swop_sign_dapp" |
---|
21 | 21 | | |
---|
22 | 22 | | let j = "config_swop_eth_dapp" |
---|
23 | 23 | | |
---|
24 | 24 | | let k = "config_confirmations_from_waves" |
---|
25 | 25 | | |
---|
26 | 26 | | let l = "config_confirmations_from_eth" |
---|
27 | 27 | | |
---|
28 | | - | let m = "conf_dapp_is_running" |
---|
| 28 | + | let m = "config_autoswap" |
---|
29 | 29 | | |
---|
30 | | - | let n = "conf_maintenance_msg" |
---|
| 30 | + | let n = "conf_dapp_is_running" |
---|
31 | 31 | | |
---|
32 | | - | let o = valueOrElse(getBoolean(this, m), true) |
---|
| 32 | + | let o = "conf_maintenance_msg" |
---|
33 | 33 | | |
---|
34 | | - | let p = valueOrElse(getString(this, n), "") |
---|
| 34 | + | let p = valueOrElse(getBoolean(this, n), true) |
---|
35 | 35 | | |
---|
36 | | - | let q = "LOCKED" |
---|
| 36 | + | let q = valueOrElse(getString(this, o), "") |
---|
37 | 37 | | |
---|
38 | | - | let r = "UNLOCKED" |
---|
| 38 | + | let r = "LOCKED" |
---|
39 | 39 | | |
---|
40 | | - | let s = "PENDING" |
---|
| 40 | + | let s = "UNLOCKED" |
---|
41 | 41 | | |
---|
42 | | - | let t = "CLOSED" |
---|
| 42 | + | let t = "PENDING" |
---|
43 | 43 | | |
---|
44 | | - | let u = "REGISTERED" |
---|
| 44 | + | let u = "CLOSED" |
---|
45 | 45 | | |
---|
46 | | - | let v = "VERIFIED" |
---|
| 46 | + | let v = "REGISTERED" |
---|
47 | 47 | | |
---|
48 | | - | let w = "FLAGGED" |
---|
| 48 | + | let w = "VERIFIED" |
---|
49 | 49 | | |
---|
50 | | - | let x = "ILLEGAL" |
---|
| 50 | + | let x = "FLAGGED" |
---|
51 | 51 | | |
---|
52 | | - | let y = "CHANGE_REQUIRED" |
---|
| 52 | + | let y = "ILLEGAL" |
---|
53 | 53 | | |
---|
54 | | - | let z = ["ETH"] |
---|
| 54 | + | let z = "CHANGE_REQUIRED" |
---|
55 | 55 | | |
---|
56 | | - | func A (B) = (("nft_" + B) + "_status") |
---|
| 56 | + | let A = ["ETH"] |
---|
| 57 | + | |
---|
| 58 | + | func B (C) = (("nft_" + C) + "_status") |
---|
57 | 59 | | |
---|
58 | 60 | | |
---|
59 | | - | func C (B,D,E) = ((((("transfer_" + B) + "_") + D) + "_") + E) |
---|
| 61 | + | func D (C,E,F) = ((((("transfer_" + C) + "_") + E) + "_") + F) |
---|
60 | 62 | | |
---|
61 | 63 | | |
---|
62 | | - | let F = "cost_non_minted" |
---|
| 64 | + | let G = "cost_non_minted" |
---|
63 | 65 | | |
---|
64 | | - | let G = "cost_minted" |
---|
| 66 | + | let H = "cost_minted" |
---|
65 | 67 | | |
---|
66 | | - | func H (I) = valueOrElse(getString(this, I), "") |
---|
| 68 | + | func I (J) = valueOrElse(getString(this, J), "") |
---|
67 | 69 | | |
---|
68 | 70 | | |
---|
69 | | - | func J (I) = valueOrElse(getInteger(this, I), 0) |
---|
| 71 | + | func K (J) = valueOrElse(getInteger(this, J), 0) |
---|
70 | 72 | | |
---|
71 | 73 | | |
---|
72 | | - | func K (I) = valueOrElse(getBoolean(this, I), false) |
---|
| 74 | + | func L (J) = valueOrElse(getBoolean(this, J), false) |
---|
73 | 75 | | |
---|
74 | 76 | | |
---|
75 | | - | let L = value(addressFromStringValue(H(c))) |
---|
| 77 | + | let M = value(addressFromStringValue(I(c))) |
---|
76 | 78 | | |
---|
77 | | - | let M = value(addressFromString(H(e))) |
---|
| 79 | + | let N = value(addressFromString(I(e))) |
---|
78 | 80 | | |
---|
79 | | - | let N = value(addressFromString(H(f))) |
---|
| 81 | + | let O = value(addressFromString(I(f))) |
---|
80 | 82 | | |
---|
81 | | - | let O = value(addressFromString(H(d))) |
---|
| 83 | + | let P = value(addressFromString(I(d))) |
---|
82 | 84 | | |
---|
83 | | - | let P = H(g) |
---|
| 85 | + | let Q = valueOrElse(L(m), false) |
---|
84 | 86 | | |
---|
85 | | - | let Q = J(h) |
---|
| 87 | + | let R = I(g) |
---|
86 | 88 | | |
---|
87 | | - | func R (I) = valueOrElse(getString(N, I), "") |
---|
| 89 | + | let S = K(h) |
---|
| 90 | + | |
---|
| 91 | + | func T (J) = valueOrElse(getString(O, J), "") |
---|
88 | 92 | | |
---|
89 | 93 | | |
---|
90 | | - | func S (I) = valueOrElse(getString(M, I), "") |
---|
| 94 | + | func U (J) = valueOrElse(getString(N, J), "") |
---|
91 | 95 | | |
---|
92 | 96 | | |
---|
93 | | - | func T (I) = valueOrErrorMessage(getInteger(O, I), "Integer undefined in oracle") |
---|
| 97 | + | func V (J) = valueOrErrorMessage(getInteger(P, J), "Integer undefined in oracle") |
---|
94 | 98 | | |
---|
95 | 99 | | |
---|
96 | | - | func U (V) = if (if (if ((V.quantity == 1)) |
---|
97 | | - | then (V.decimals == 0) |
---|
| 100 | + | func W (X) = if (if (if ((X.quantity == 1)) |
---|
| 101 | + | then (X.decimals == 0) |
---|
98 | 102 | | else false) |
---|
99 | | - | then (V.reissuable == false) |
---|
| 103 | + | then (X.reissuable == false) |
---|
100 | 104 | | else false) |
---|
101 | | - | then (V.issuer == M) |
---|
| 105 | + | then (X.issuer == N) |
---|
102 | 106 | | else false |
---|
103 | 107 | | |
---|
104 | 108 | | |
---|
105 | | - | func W (X) = { |
---|
106 | | - | let V = value(assetInfo(X)) |
---|
107 | | - | U(V) |
---|
| 109 | + | func Y (Z) = { |
---|
| 110 | + | let X = value(assetInfo(Z)) |
---|
| 111 | + | W(X) |
---|
108 | 112 | | } |
---|
109 | 113 | | |
---|
110 | 114 | | |
---|
111 | | - | func Y (Z) = if ((size(Z.payments) != 2)) |
---|
| 115 | + | func aa (ab) = if ((size(ab.payments) != 2)) |
---|
112 | 116 | | then throw("Need to attach 2 payments") |
---|
113 | 117 | | else { |
---|
114 | | - | let aa = value(Z.payments[0]) |
---|
115 | | - | let ab = value(aa.amount) |
---|
116 | | - | let ac = value(Z.payments[1]) |
---|
| 118 | + | let ac = value(ab.payments[0]) |
---|
117 | 119 | | let ad = value(ac.amount) |
---|
118 | | - | $Tuple4(aa, ab, ac, ad) |
---|
| 120 | + | let ae = value(ab.payments[1]) |
---|
| 121 | + | let af = value(ae.amount) |
---|
| 122 | + | $Tuple4(ac, ad, ae, af) |
---|
119 | 123 | | } |
---|
120 | 124 | | |
---|
121 | 125 | | |
---|
122 | | - | let ae = valueOrElse(K(b), false) |
---|
| 126 | + | let ag = valueOrElse(L(b), false) |
---|
123 | 127 | | |
---|
124 | | - | func af (Z) = { |
---|
125 | | - | let E = toString(Z.caller) |
---|
126 | | - | let X = toBase58String(Z.transactionId) |
---|
127 | | - | let ag = if (ae) |
---|
128 | | - | then [toString(L), toString(this)] |
---|
| 128 | + | func ah (ab) = { |
---|
| 129 | + | let F = toString(ab.caller) |
---|
| 130 | + | let Z = toBase58String(ab.transactionId) |
---|
| 131 | + | let ai = if (ag) |
---|
| 132 | + | then [toString(M), toString(this)] |
---|
129 | 133 | | else [toString(this)] |
---|
130 | | - | containsElement(ag, E) |
---|
| 134 | + | containsElement(ai, F) |
---|
131 | 135 | | } |
---|
132 | 136 | | |
---|
133 | 137 | | |
---|
134 | | - | func ah (Z) = if (!(o)) |
---|
135 | | - | then throw(p) |
---|
136 | | - | else $Tuple3(toBase58String(Z.transactionId), toBase58String(Z.caller.bytes), lastBlock.timestamp) |
---|
| 138 | + | func aj (ab) = if (!(p)) |
---|
| 139 | + | then throw(q) |
---|
| 140 | + | else $Tuple3(toBase58String(ab.transactionId), toBase58String(ab.caller.bytes), lastBlock.timestamp) |
---|
137 | 141 | | |
---|
138 | 142 | | |
---|
139 | | - | func ai (aj) = { |
---|
140 | | - | let ak = S(("nft_" + aj)) |
---|
141 | | - | let al = split(ak, "_")[6] |
---|
142 | | - | let am = split(ak, "_")[5] |
---|
143 | | - | $Tuple2(al, am) |
---|
| 143 | + | func ak (al) = { |
---|
| 144 | + | let am = U(("nft_" + al)) |
---|
| 145 | + | let an = split(am, "_")[6] |
---|
| 146 | + | let ao = split(am, "_")[5] |
---|
| 147 | + | $Tuple2(an, ao) |
---|
144 | 148 | | } |
---|
145 | 149 | | |
---|
146 | 150 | | |
---|
147 | | - | func an (ao) = R(("user_ERC20_" + ao)) |
---|
| 151 | + | func ap (aq) = T(("user_ERC20_" + aq)) |
---|
148 | 152 | | |
---|
149 | 153 | | |
---|
150 | | - | func ap (ao) = R(("user_status_" + ao)) |
---|
| 154 | + | func ar (aq) = T(("user_status_" + aq)) |
---|
151 | 155 | | |
---|
152 | 156 | | |
---|
153 | | - | func aq (am,ao) = S(((("art_flag_" + am) + "_") + ao)) |
---|
| 157 | + | func as (ao,aq) = U(((("art_flag_" + ao) + "_") + aq)) |
---|
154 | 158 | | |
---|
155 | 159 | | |
---|
156 | | - | func ar (as) = if ((as == u)) |
---|
| 160 | + | func at (au) = if ((au == v)) |
---|
157 | 161 | | then true |
---|
158 | | - | else (as == v) |
---|
| 162 | + | else (au == w) |
---|
159 | 163 | | |
---|
160 | 164 | | |
---|
161 | | - | func at (as) = if (if ((as != w)) |
---|
162 | | - | then (as != x) |
---|
| 165 | + | func av (au) = if (if ((au != x)) |
---|
| 166 | + | then (au != y) |
---|
163 | 167 | | else false) |
---|
164 | | - | then (as != y) |
---|
| 168 | + | then (au != z) |
---|
165 | 169 | | else false |
---|
166 | 170 | | |
---|
167 | 171 | | |
---|
168 | | - | func au (ao) = if ((size(ao) == 42)) |
---|
169 | | - | then (take(ao, 2) == "0x") |
---|
| 172 | + | func aw (aq) = if ((size(aq) == 42)) |
---|
| 173 | + | then (take(aq, 2) == "0x") |
---|
170 | 174 | | else false |
---|
171 | 175 | | |
---|
172 | 176 | | |
---|
173 | | - | func av (aw,ax) = [StringEntry(i, aw), StringEntry(j, ax)] |
---|
| 177 | + | func ax (ay,az) = [StringEntry(i, ay), StringEntry(j, az)] |
---|
174 | 178 | | |
---|
175 | 179 | | |
---|
176 | | - | func ay (az,aA) = { |
---|
177 | | - | let V = assetInfo(fromBase58String(az)) |
---|
178 | | - | let aB = value(V).decimals |
---|
179 | | - | let aC = pow(aA, 0, 10, 1, aB, HALFUP) |
---|
180 | | - | [StringEntry(g, az), IntegerEntry(h, aC)] |
---|
| 180 | + | func aA (aB,aC) = { |
---|
| 181 | + | let X = assetInfo(fromBase58String(aB)) |
---|
| 182 | + | let aD = value(X).decimals |
---|
| 183 | + | let aE = pow(aC, 0, 10, 1, aD, HALFUP) |
---|
| 184 | + | [StringEntry(g, aB), IntegerEntry(h, aE)] |
---|
181 | 185 | | } |
---|
182 | 186 | | |
---|
183 | 187 | | |
---|
184 | | - | func aD (aE,aF) = [IntegerEntry(k, aE), IntegerEntry(l, aF)] |
---|
| 188 | + | func aF (aG,aH) = [IntegerEntry(k, aG), IntegerEntry(l, aH)] |
---|
185 | 189 | | |
---|
186 | 190 | | |
---|
187 | | - | @Callable(Z) |
---|
188 | | - | func init (aG,O,M,N,az,aA,aw,ax,aE,aF) = if (af(Z)) |
---|
| 191 | + | func aI (Q) = [BooleanEntry(m, Q)] |
---|
| 192 | + | |
---|
| 193 | + | |
---|
| 194 | + | @Callable(ab) |
---|
| 195 | + | func init (aJ,P,N,O,aB,aC,ay,az,aG,aH,Q) = if (ah(ab)) |
---|
189 | 196 | | then { |
---|
190 | | - | let aH = av(aw, ax) |
---|
191 | | - | let aI = ay(az, aA) |
---|
192 | | - | let aJ = aD(aE, aF) |
---|
193 | | - | ((([StringEntry(c, aG), StringEntry(d, O), StringEntry(e, M), StringEntry(f, N), BooleanEntry(b, true)] ++ aH) ++ aI) ++ aJ) |
---|
| 197 | + | let aK = ax(ay, az) |
---|
| 198 | + | let aL = aA(aB, aC) |
---|
| 199 | + | let aM = aF(aG, aH) |
---|
| 200 | + | let aN = aI(Q) |
---|
| 201 | + | (((([StringEntry(c, aJ), StringEntry(d, P), StringEntry(e, N), StringEntry(f, O), BooleanEntry(b, true)] ++ aK) ++ aL) ++ aM) ++ aN) |
---|
194 | 202 | | } |
---|
195 | 203 | | else throw("Not allowed") |
---|
196 | 204 | | |
---|
197 | 205 | | |
---|
198 | 206 | | |
---|
199 | | - | @Callable(Z) |
---|
200 | | - | func setSwopDapps (aw,ax) = if (af(Z)) |
---|
201 | | - | then av(aw, ax) |
---|
| 207 | + | @Callable(ab) |
---|
| 208 | + | func setSwopDapps (ay,az) = if (ah(ab)) |
---|
| 209 | + | then ax(ay, az) |
---|
202 | 210 | | else throw("Not allowed") |
---|
203 | 211 | | |
---|
204 | 212 | | |
---|
205 | 213 | | |
---|
206 | | - | @Callable(Z) |
---|
207 | | - | func setFee (az,aA) = if (af(Z)) |
---|
208 | | - | then ay(az, aA) |
---|
| 214 | + | @Callable(ab) |
---|
| 215 | + | func setFee (aB,aC) = if (ah(ab)) |
---|
| 216 | + | then aA(aB, aC) |
---|
209 | 217 | | else throw("Not allowed") |
---|
210 | 218 | | |
---|
211 | 219 | | |
---|
212 | 220 | | |
---|
213 | | - | @Callable(Z) |
---|
214 | | - | func setConfirmations (aE,aF) = if (af(Z)) |
---|
215 | | - | then aD(aE, aF) |
---|
| 221 | + | @Callable(ab) |
---|
| 222 | + | func setConfirmations (aG,aH) = if (ah(ab)) |
---|
| 223 | + | then aF(aG, aH) |
---|
216 | 224 | | else throw("Not allowed") |
---|
217 | 225 | | |
---|
218 | 226 | | |
---|
219 | 227 | | |
---|
220 | | - | @Callable(Z) |
---|
221 | | - | func lock (aK,aL) = if (!(ae)) |
---|
| 228 | + | @Callable(ab) |
---|
| 229 | + | func setAutoswap (Q) = if (ah(ab)) |
---|
| 230 | + | then aI(Q) |
---|
| 231 | + | else throw("Not allowed") |
---|
| 232 | + | |
---|
| 233 | + | |
---|
| 234 | + | |
---|
| 235 | + | @Callable(ab) |
---|
| 236 | + | func lock (aO,aP) = if (!(ag)) |
---|
222 | 237 | | then throw("dApp not ready") |
---|
223 | | - | else if (!(containsElement(z, aL))) |
---|
| 238 | + | else if (!(containsElement(A, aP))) |
---|
224 | 239 | | then throw("Network not supported") |
---|
225 | | - | else if (!(au(aK))) |
---|
| 240 | + | else if (!(aw(aO))) |
---|
226 | 241 | | then throw("Wrong recipient address") |
---|
227 | 242 | | else { |
---|
228 | | - | let aM = ah(Z) |
---|
229 | | - | let X = aM._1 |
---|
230 | | - | let E = aM._2 |
---|
231 | | - | let aN = aM._3 |
---|
232 | | - | let aO = Y(Z) |
---|
233 | | - | let aa = aO._1 |
---|
234 | | - | let ab = aO._2 |
---|
235 | | - | let ac = aO._3 |
---|
236 | | - | let ad = aO._4 |
---|
237 | | - | if ((ab != 1)) |
---|
| 243 | + | let aQ = aj(ab) |
---|
| 244 | + | let Z = aQ._1 |
---|
| 245 | + | let F = aQ._2 |
---|
| 246 | + | let aR = aQ._3 |
---|
| 247 | + | let aS = aa(ab) |
---|
| 248 | + | let ac = aS._1 |
---|
| 249 | + | let ad = aS._2 |
---|
| 250 | + | let ae = aS._3 |
---|
| 251 | + | let af = aS._4 |
---|
| 252 | + | if ((ad != 1)) |
---|
238 | 253 | | then throw("No NFT attached") |
---|
239 | 254 | | else { |
---|
240 | | - | let B = if (if (isDefined(aa.assetId)) |
---|
241 | | - | then W(value(aa.assetId)) |
---|
| 255 | + | let C = if (if (isDefined(ac.assetId)) |
---|
| 256 | + | then Y(value(ac.assetId)) |
---|
242 | 257 | | else false) |
---|
243 | | - | then toBase58String(value(aa.assetId)) |
---|
| 258 | + | then toBase58String(value(ac.assetId)) |
---|
244 | 259 | | else throw("Only SIGN Art NFT accepted.") |
---|
245 | | - | let aP = ai(B) |
---|
246 | | - | let al = aP._1 |
---|
247 | | - | let am = aP._2 |
---|
248 | | - | if (!(ar(ap(al)))) |
---|
249 | | - | then throw(("Creator status is :" + ap(al))) |
---|
250 | | - | else if (!(at(aq(am, al)))) |
---|
251 | | - | then throw(("Artwork status is :" + aq(am, al))) |
---|
| 260 | + | let aT = ak(C) |
---|
| 261 | + | let an = aT._1 |
---|
| 262 | + | let ao = aT._2 |
---|
| 263 | + | if (!(at(ar(an)))) |
---|
| 264 | + | then throw(("Creator status is :" + ar(an))) |
---|
| 265 | + | else if (!(av(as(ao, an)))) |
---|
| 266 | + | then throw(("Artwork status is :" + as(ao, an))) |
---|
252 | 267 | | else { |
---|
253 | | - | let aQ = an(al) |
---|
254 | | - | if ((size(aQ) == 0)) |
---|
| 268 | + | let aU = ap(an) |
---|
| 269 | + | if ((size(aU) == 0)) |
---|
255 | 270 | | then throw("This artist didn't allow crosschain transfer") |
---|
256 | 271 | | else { |
---|
257 | | - | let aR = H(A(B)) |
---|
258 | | - | if (if ((aR == q)) |
---|
| 272 | + | let aV = I(B(C)) |
---|
| 273 | + | if (if ((aV == r)) |
---|
259 | 274 | | then true |
---|
260 | | - | else (aR == s)) |
---|
| 275 | + | else (aV == t)) |
---|
261 | 276 | | then throw("NFT already locked") |
---|
262 | 277 | | else { |
---|
263 | | - | let aS = T(F) |
---|
264 | | - | let aT = T(G) |
---|
265 | | - | let aU = if ((aR == r)) |
---|
| 278 | + | let aW = V(G) |
---|
| 279 | + | let aX = V(H) |
---|
| 280 | + | let aY = if ((aV == s)) |
---|
266 | 281 | | then true |
---|
267 | 282 | | else false |
---|
268 | | - | if (if (!(isDefined(ac.assetId))) |
---|
| 283 | + | if (if (!(isDefined(ae.assetId))) |
---|
269 | 284 | | then true |
---|
270 | | - | else (toBase58String(value(ac.assetId)) != P)) |
---|
| 285 | + | else (toBase58String(value(ae.assetId)) != R)) |
---|
271 | 286 | | then throw("Wrong payment asset") |
---|
272 | | - | else if (if (aU) |
---|
273 | | - | then (ad > (aT + Q)) |
---|
| 287 | + | else if (if (aY) |
---|
| 288 | + | then (af > (aX + S)) |
---|
274 | 289 | | else false) |
---|
275 | 290 | | then throw("Wrong payment amount to unlock") |
---|
276 | | - | else if (if (!(aU)) |
---|
277 | | - | then (ad > (aS + Q)) |
---|
| 291 | + | else if (if (!(aY)) |
---|
| 292 | + | then (af > (aW + S)) |
---|
278 | 293 | | else false) |
---|
279 | 294 | | then throw("Wrong payment amount to mint and unlock") |
---|
280 | 295 | | else { |
---|
281 | | - | let aV = if (aU) |
---|
282 | | - | then aT |
---|
283 | | - | else aS |
---|
284 | | - | let aW = invoke(addressFromStringValue(H(i)), "exchange", [1], [AttachedPayment(fromBase58String(P), Q)]) |
---|
285 | | - | if ((aW == aW)) |
---|
| 296 | + | let aZ = if (aY) |
---|
| 297 | + | then aX |
---|
| 298 | + | else aW |
---|
| 299 | + | let ba = if (Q) |
---|
| 300 | + | then invoke(addressFromStringValue(I(i)), "exchange", [1], [AttachedPayment(fromBase58String(R), S)]) |
---|
| 301 | + | else unit |
---|
| 302 | + | if ((ba == ba)) |
---|
286 | 303 | | then { |
---|
287 | | - | let aX = invoke(addressFromStringValue(H(j)), "exchange", [1], [AttachedPayment(fromBase58String(P), aV)]) |
---|
288 | | - | if ((aX == aX)) |
---|
289 | | - | then [StringEntry(A(B), s), StringEntry(((C(B, X, E) + "_") + s), ((((((((((((aK + "_") + aL) + "_") + E) + "_") + X) + "_") + value(assetInfo(value(aa.assetId))).name) + "_") + toString(aN)) + "_") + toString(height)))] |
---|
| 304 | + | let bb = if (Q) |
---|
| 305 | + | then invoke(addressFromStringValue(I(j)), "exchange", [1], [AttachedPayment(fromBase58String(R), aZ)]) |
---|
| 306 | + | else unit |
---|
| 307 | + | if ((bb == bb)) |
---|
| 308 | + | then [StringEntry(B(C), t), StringEntry(((D(C, Z, F) + "_") + t), ((((((((((((aO + "_") + aP) + "_") + F) + "_") + Z) + "_") + value(assetInfo(value(ac.assetId))).name) + "_") + toString(aR)) + "_") + toString(height)))] |
---|
290 | 309 | | else throw("Strict value is not equal to itself.") |
---|
291 | 310 | | } |
---|
292 | 311 | | else throw("Strict value is not equal to itself.") |
---|
293 | 312 | | } |
---|
294 | 313 | | } |
---|
295 | 314 | | } |
---|
296 | 315 | | } |
---|
297 | 316 | | } |
---|
298 | 317 | | } |
---|
299 | 318 | | |
---|
300 | 319 | | |
---|
301 | 320 | | |
---|
302 | | - | @Callable(Z) |
---|
303 | | - | func confirmLock (B,aY,E) = if (!(ae)) |
---|
| 321 | + | @Callable(ab) |
---|
| 322 | + | func confirmLock (C,bc,F) = if (!(ag)) |
---|
304 | 323 | | then throw("dApp not ready") |
---|
305 | | - | else if (af(Z)) |
---|
| 324 | + | else if (ah(ab)) |
---|
306 | 325 | | then { |
---|
307 | | - | let aR = H(A(B)) |
---|
308 | | - | if ((aR != s)) |
---|
| 326 | + | let aV = I(B(C)) |
---|
| 327 | + | if ((aV != t)) |
---|
309 | 328 | | then throw("NFT not pending") |
---|
310 | 329 | | else { |
---|
311 | | - | let aZ = H(((C(B, aY, E) + "_") + s)) |
---|
312 | | - | let ba = ((C(B, aY, E) + "_") + t) |
---|
313 | | - | [DeleteEntry(((C(B, aY, E) + "_") + s)), StringEntry(ba, aZ), StringEntry(A(B), q)] |
---|
| 330 | + | let bd = I(((D(C, bc, F) + "_") + t)) |
---|
| 331 | + | let be = ((D(C, bc, F) + "_") + u) |
---|
| 332 | + | [DeleteEntry(((D(C, bc, F) + "_") + t)), StringEntry(be, bd), StringEntry(B(C), r)] |
---|
314 | 333 | | } |
---|
315 | 334 | | } |
---|
316 | 335 | | else throw("Not allowed") |
---|
317 | 336 | | |
---|
318 | 337 | | |
---|
319 | 338 | | |
---|
320 | | - | @Callable(Z) |
---|
321 | | - | func unlock (aK,B) = if (!(ae)) |
---|
| 339 | + | @Callable(ab) |
---|
| 340 | + | func unlock (aO,C) = if (!(ag)) |
---|
322 | 341 | | then throw("dApp not ready") |
---|
323 | | - | else if (af(Z)) |
---|
| 342 | + | else if (ah(ab)) |
---|
324 | 343 | | then { |
---|
325 | | - | let aR = H(A(B)) |
---|
326 | | - | if ((aR != q)) |
---|
| 344 | + | let aV = I(B(C)) |
---|
| 345 | + | if ((aV != r)) |
---|
327 | 346 | | then throw("NFT not locked, finalize first if pending") |
---|
328 | | - | else [StringEntry(A(B), r), ScriptTransfer(Address(fromBase58String(aK)), 1, fromBase58String(B))] |
---|
| 347 | + | else [StringEntry(B(C), s), ScriptTransfer(Address(fromBase58String(aO)), 1, fromBase58String(C))] |
---|
329 | 348 | | } |
---|
330 | 349 | | else throw("Not allowed") |
---|
331 | 350 | | |
---|
332 | 351 | | |
---|
333 | 352 | | |
---|
334 | | - | @Callable(Z) |
---|
335 | | - | func appRunning (bb,bc) = if (!(ae)) |
---|
| 353 | + | @Callable(ab) |
---|
| 354 | + | func appRunning (bf,bg) = if (!(ag)) |
---|
336 | 355 | | then throw("dApp not ready") |
---|
337 | | - | else if (af(Z)) |
---|
338 | | - | then [BooleanEntry(m, bb), StringEntry(n, bc)] |
---|
| 356 | + | else if (ah(ab)) |
---|
| 357 | + | then [BooleanEntry(n, bf), StringEntry(o, bg)] |
---|
339 | 358 | | else throw("You are not allowed to change this") |
---|
340 | 359 | | |
---|
341 | 360 | | |
---|
342 | 361 | | |
---|
343 | | - | @Callable(Z) |
---|
344 | | - | func deleteEntry (bd) = if (af(Z)) |
---|
345 | | - | then [DeleteEntry(bd)] |
---|
| 362 | + | @Callable(ab) |
---|
| 363 | + | func deleteEntry (bh) = if (ah(ab)) |
---|
| 364 | + | then [DeleteEntry(bh)] |
---|
346 | 365 | | else throw("no") |
---|
347 | 366 | | |
---|
348 | 367 | | |
---|