tx · a7ZiuokMsqt4fkEypEM66ff7HoLfBXpczvTQSvtiuSv 3NBwZbvD45CscLGF78qTaDRBZ7mDBHt3Yib: -0.00900000 Waves 2022.08.10 08:02 [2177906] smart account 3NBwZbvD45CscLGF78qTaDRBZ7mDBHt3Yib > SELF 0.00000000 Waves
{ "type": 13, "id": "a7ZiuokMsqt4fkEypEM66ff7HoLfBXpczvTQSvtiuSv", "fee": 900000, "feeAssetId": null, "timestamp": 1660107777135, "version": 2, "chainId": 84, "sender": "3NBwZbvD45CscLGF78qTaDRBZ7mDBHt3Yib", "senderPublicKey": "3q3N8Kv49DbzNHyTB4A87UYz2DdquXCgP3GNCcD9Zj66", "proofs": [ "2AcWoZRc8BdtaTGHz6LZCQBMiGApynA5UU2eFp4miMAS7sYjiS6GaouETJaVBiKED5b2wJzsN38yMT8HSZ2KqGrJ" ], "script": "base64:AAIFAAAAAAAAAC0IAhIGCgQICAgIEgQKAggBEgQKAggIEgQKAggIEgQKAggIEgQKAgQIEgMKAQgAAAAoAAAAAAtDT05GX0lOSVRfSwIAAAALY29uZmlnX2luaXQAAAAAC0NPTkZfQU1JTl9LAgAAAAxjb25maWdfYWRtaW4AAAAADUNPTkZfT1JBQ0xFX0sCAAAADWNvbmZpZ19vcmFjbGUAAAAAE0NPTkZfQVJUV09SS19EQVBQX0sCAAAAE2NvbmZpZ19hcnR3b3JrX2RhcHAAAAAAEUNPTkZfVVNFUlNfREFQUF9LAgAAABFjb25maWdfdXNlcnNfZGFwcAAAAAAQQ09ORl9GRUVfQVNTRVRfSwIAAAAQY29uZmlnX2ZlZV9hc3NldAAAAAARQ09ORl9GRUVfQU1PVU5UX0sCAAAAEWNvbmZpZ19mZWVfYW1vdW50AAAAAA5kYXBwUnVubmluZ0tleQIAAAAUY29uZl9kYXBwX2lzX3J1bm5pbmcAAAAAEW1haW50ZW5hbmNlTVNHS2V5AgAAABRjb25mX21haW50ZW5hbmNlX21zZwAAAAALZGFwcFJ1bm5pbmcJAQAAAAt2YW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ldGVFbnRyeQAAAAEAAAAFZW50cnkDCQEAAAAJb3duZXJPbmx5AAAAAQUAAAABaQkABEwAAAACCQEAAAALRGVsZXRlRW50cnkAAAABBQAAAAVlbnRyeQUAAAADbmlsCQAAAgAAAAECAAAAAm5vAAAAACSGdIQ=", "height": 2177906, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: DxzYKeVJmXCkQCbafk4NMGdp9zYF4FMnUrNBFZ3GQXHQ Next: 3aGqYGUhmHpimanQ8Ujifh6M5ZbNtPSxe7PPzSZJsfm2 Diff:
Old | New | Differences | |
---|---|---|---|
61 | 61 | let oracleAddr = value(addressFromString(getStringByKey(CONF_ORACLE_K))) | |
62 | 62 | ||
63 | 63 | let feeAcceptedAsset = getStringByKey(CONF_FEE_ASSET_K) | |
64 | + | ||
65 | + | let feeAcceptedAmountForSign = getIntegerByKey(CONF_FEE_AMOUNT_K) | |
64 | 66 | ||
65 | 67 | func getStringFromUsersByKey (key) = valueOrElse(getString(usersDapp, key), "") | |
66 | 68 | ||
154 | 156 | else if (!(containsElement(NETWORKS, network))) | |
155 | 157 | then throw("Network not supported") | |
156 | 158 | else { | |
157 | - | let $ | |
158 | - | let id = $ | |
159 | - | let caller = $ | |
160 | - | let date = $ | |
161 | - | let $ | |
162 | - | let nft_payment = $ | |
163 | - | let nft_amount = $ | |
164 | - | let gateway_payment = $ | |
165 | - | let gateway_amount = $ | |
159 | + | let $t044264465 = idCallerDate(i) | |
160 | + | let id = $t044264465._1 | |
161 | + | let caller = $t044264465._2 | |
162 | + | let date = $t044264465._3 | |
163 | + | let $t044684545 = isPayment(i) | |
164 | + | let nft_payment = $t044684545._1 | |
165 | + | let nft_amount = $t044684545._2 | |
166 | + | let gateway_payment = $t044684545._3 | |
167 | + | let gateway_amount = $t044684545._4 | |
166 | 168 | if ((nft_amount != 1)) | |
167 | 169 | then throw("No NFT attached") | |
168 | 170 | else { | |
192 | 194 | else (toBase58String(value(gateway_payment.assetId)) != feeAcceptedAsset)) | |
193 | 195 | then throw("Wrong payment asset") | |
194 | 196 | else if (if (isMinted) | |
195 | - | then (gateway_amount > gasFeeMinted) | |
197 | + | then ((gateway_amount + feeAcceptedAmountForSign) > gasFeeMinted) | |
196 | 198 | else false) | |
197 | 199 | then throw("Wrong payment amount to unlock") | |
198 | 200 | else if (if (!(isMinted)) | |
199 | - | then (gateway_amount > gasFeeNonMinted) | |
201 | + | then ((gateway_amount + feeAcceptedAmountForSign) > gasFeeNonMinted) | |
200 | 202 | else false) | |
201 | 203 | then throw("Wrong payment amount to mint and unlock") | |
202 | 204 | else [StringEntry(keyNFTstatus(nftId), status_PENDING), StringEntry(((keyTransferNFT(nftId, id) + "_") + status_PENDING), ((((((((((((recipient + "_") + network) + "_") + caller) + "_") + id) + "_") + value(assetInfo(value(nft_payment.assetId))).name) + "_") + toString(date)) + "_") + toString(height)))] |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let CONF_INIT_K = "config_init" | |
5 | 5 | ||
6 | 6 | let CONF_AMIN_K = "config_admin" | |
7 | 7 | ||
8 | 8 | let CONF_ORACLE_K = "config_oracle" | |
9 | 9 | ||
10 | 10 | let CONF_ARTWORK_DAPP_K = "config_artwork_dapp" | |
11 | 11 | ||
12 | 12 | let CONF_USERS_DAPP_K = "config_users_dapp" | |
13 | 13 | ||
14 | 14 | let CONF_FEE_ASSET_K = "config_fee_asset" | |
15 | 15 | ||
16 | 16 | let CONF_FEE_AMOUNT_K = "config_fee_amount" | |
17 | 17 | ||
18 | 18 | let dappRunningKey = "conf_dapp_is_running" | |
19 | 19 | ||
20 | 20 | let maintenanceMSGKey = "conf_maintenance_msg" | |
21 | 21 | ||
22 | 22 | let dappRunning = valueOrElse(getBoolean(this, dappRunningKey), true) | |
23 | 23 | ||
24 | 24 | let maintenanceMSG = valueOrElse(getString(this, maintenanceMSGKey), "") | |
25 | 25 | ||
26 | 26 | let status_LOCKED = "LOCKED" | |
27 | 27 | ||
28 | 28 | let status_UNLOCKED = "UNLOCKED" | |
29 | 29 | ||
30 | 30 | let status_PENDING = "PENDING" | |
31 | 31 | ||
32 | 32 | let status_CLOSED = "CLOSED" | |
33 | 33 | ||
34 | 34 | let NETWORKS = ["ETH", "POLYGON"] | |
35 | 35 | ||
36 | 36 | func keyNFTstatus (nftId) = (("nft_" + nftId) + "_status") | |
37 | 37 | ||
38 | 38 | ||
39 | 39 | func keyTransferNFT (nftId,txid) = ((("transfer_" + nftId) + "_") + txid) | |
40 | 40 | ||
41 | 41 | ||
42 | 42 | let keyFeeNonMinted = "cost_non_minted" | |
43 | 43 | ||
44 | 44 | let keyFeeMinted = "cost_minted" | |
45 | 45 | ||
46 | 46 | func getStringByKey (key) = valueOrElse(getString(this, key), "") | |
47 | 47 | ||
48 | 48 | ||
49 | 49 | func getIntegerByKey (key) = valueOrElse(getInteger(this, key), 0) | |
50 | 50 | ||
51 | 51 | ||
52 | 52 | func getBooleanByKey (key) = valueOrElse(getBoolean(this, key), false) | |
53 | 53 | ||
54 | 54 | ||
55 | 55 | let admin = value(addressFromString(getStringByKey(CONF_AMIN_K))) | |
56 | 56 | ||
57 | 57 | let artworksDapp = value(addressFromString(getStringByKey(CONF_ARTWORK_DAPP_K))) | |
58 | 58 | ||
59 | 59 | let usersDapp = value(addressFromString(getStringByKey(CONF_USERS_DAPP_K))) | |
60 | 60 | ||
61 | 61 | let oracleAddr = value(addressFromString(getStringByKey(CONF_ORACLE_K))) | |
62 | 62 | ||
63 | 63 | let feeAcceptedAsset = getStringByKey(CONF_FEE_ASSET_K) | |
64 | + | ||
65 | + | let feeAcceptedAmountForSign = getIntegerByKey(CONF_FEE_AMOUNT_K) | |
64 | 66 | ||
65 | 67 | func getStringFromUsersByKey (key) = valueOrElse(getString(usersDapp, key), "") | |
66 | 68 | ||
67 | 69 | ||
68 | 70 | func getStringFromArtworksByKey (key) = valueOrElse(getString(artworksDapp, key), "") | |
69 | 71 | ||
70 | 72 | ||
71 | 73 | func getIntegerByKeyFromOracle (key) = valueOrErrorMessage(getInteger(oracleAddr, key), "Integer undefine or 0 in oracle") | |
72 | 74 | ||
73 | 75 | ||
74 | 76 | func assetIsValid (assetDetails) = if (if (if ((assetDetails.quantity == 1)) | |
75 | 77 | then (assetDetails.decimals == 0) | |
76 | 78 | else false) | |
77 | 79 | then (assetDetails.reissuable == false) | |
78 | 80 | else false) | |
79 | 81 | then (assetDetails.issuer == artworksDapp) | |
80 | 82 | else false | |
81 | 83 | ||
82 | 84 | ||
83 | 85 | func isSignArtNFT (id) = { | |
84 | 86 | let assetDetails = value(assetInfo(id)) | |
85 | 87 | assetIsValid(assetDetails) | |
86 | 88 | } | |
87 | 89 | ||
88 | 90 | ||
89 | 91 | func isPayment (i) = if ((size(i.payments) == 0)) | |
90 | 92 | then throw("No payment attached") | |
91 | 93 | else { | |
92 | 94 | let nft_payment = value(i.payments[0]) | |
93 | 95 | let nft_amount = value(nft_payment.amount) | |
94 | 96 | let gateway_payment = value(i.payments[1]) | |
95 | 97 | let gateway_amount = value(gateway_payment.amount) | |
96 | 98 | $Tuple4(nft_payment, nft_amount, gateway_payment, gateway_amount) | |
97 | 99 | } | |
98 | 100 | ||
99 | 101 | ||
100 | 102 | let isInit = valueOrElse(getBooleanByKey(CONF_INIT_K), false) | |
101 | 103 | ||
102 | 104 | func ownerOnly (i) = { | |
103 | 105 | let caller = toString(i.caller) | |
104 | 106 | let id = toBase58String(i.transactionId) | |
105 | 107 | let allowedArr = if (isInit) | |
106 | 108 | then [toString(admin), toString(this)] | |
107 | 109 | else [toString(this)] | |
108 | 110 | if (containsElement(allowedArr, caller)) | |
109 | 111 | then true | |
110 | 112 | else false | |
111 | 113 | } | |
112 | 114 | ||
113 | 115 | ||
114 | 116 | func idCallerDate (i) = if (!(dappRunning)) | |
115 | 117 | then throw(maintenanceMSG) | |
116 | 118 | else $Tuple3(toBase58String(i.transactionId), toBase58String(i.caller.bytes), lastBlock.timestamp) | |
117 | 119 | ||
118 | 120 | ||
119 | 121 | func getCreatorFromNFTid (nftid) = { | |
120 | 122 | let nftData = getStringFromArtworksByKey(("nft_" + nftid)) | |
121 | 123 | let creator = split(nftData, "_")[6] | |
122 | 124 | creator | |
123 | 125 | } | |
124 | 126 | ||
125 | 127 | ||
126 | 128 | func getCreatorERC20Addr (addr) = { | |
127 | 129 | let erc20Addr = getStringFromUsersByKey(("user_ERC20_" + addr)) | |
128 | 130 | erc20Addr | |
129 | 131 | } | |
130 | 132 | ||
131 | 133 | ||
132 | 134 | @Callable(i) | |
133 | 135 | func init (adminAddr,oracleAddr,artworksDapp,usersDapp) = if (ownerOnly(i)) | |
134 | 136 | then [StringEntry(CONF_AMIN_K, adminAddr), StringEntry(CONF_ORACLE_K, oracleAddr), StringEntry(CONF_ARTWORK_DAPP_K, artworksDapp), StringEntry(CONF_USERS_DAPP_K, usersDapp), BooleanEntry(CONF_INIT_K, true)] | |
135 | 137 | else throw("Not allowed") | |
136 | 138 | ||
137 | 139 | ||
138 | 140 | ||
139 | 141 | @Callable(i) | |
140 | 142 | func setFee (feeAsset,feeAmount) = { | |
141 | 143 | let assetDetails = assetInfo(fromBase58String(feeAsset)) | |
142 | 144 | let decimal = value(assetDetails).decimals | |
143 | 145 | let base10FeeAmount = pow(feeAmount, 0, 10, 1, decimal, HALFUP) | |
144 | 146 | if (ownerOnly(i)) | |
145 | 147 | then [StringEntry(CONF_FEE_ASSET_K, feeAsset), IntegerEntry(CONF_FEE_AMOUNT_K, base10FeeAmount)] | |
146 | 148 | else throw("Not allowed") | |
147 | 149 | } | |
148 | 150 | ||
149 | 151 | ||
150 | 152 | ||
151 | 153 | @Callable(i) | |
152 | 154 | func lock (recipient,network) = if (!(isInit)) | |
153 | 155 | then throw("dApp not ready") | |
154 | 156 | else if (!(containsElement(NETWORKS, network))) | |
155 | 157 | then throw("Network not supported") | |
156 | 158 | else { | |
157 | - | let $ | |
158 | - | let id = $ | |
159 | - | let caller = $ | |
160 | - | let date = $ | |
161 | - | let $ | |
162 | - | let nft_payment = $ | |
163 | - | let nft_amount = $ | |
164 | - | let gateway_payment = $ | |
165 | - | let gateway_amount = $ | |
159 | + | let $t044264465 = idCallerDate(i) | |
160 | + | let id = $t044264465._1 | |
161 | + | let caller = $t044264465._2 | |
162 | + | let date = $t044264465._3 | |
163 | + | let $t044684545 = isPayment(i) | |
164 | + | let nft_payment = $t044684545._1 | |
165 | + | let nft_amount = $t044684545._2 | |
166 | + | let gateway_payment = $t044684545._3 | |
167 | + | let gateway_amount = $t044684545._4 | |
166 | 168 | if ((nft_amount != 1)) | |
167 | 169 | then throw("No NFT attached") | |
168 | 170 | else { | |
169 | 171 | let nftId = if (if (isDefined(nft_payment.assetId)) | |
170 | 172 | then isSignArtNFT(value(nft_payment.assetId)) | |
171 | 173 | else false) | |
172 | 174 | then toBase58String(value(nft_payment.assetId)) | |
173 | 175 | else throw("Only SIGN Art NFT accepted.") | |
174 | 176 | let creatorFromNFTId = getCreatorFromNFTid(nftId) | |
175 | 177 | let erc20Addr = getCreatorERC20Addr(creatorFromNFTId) | |
176 | 178 | if ((size(erc20Addr) == 0)) | |
177 | 179 | then throw("This artist didn't allow crosschain transfer") | |
178 | 180 | else { | |
179 | 181 | let nftStatus = getStringByKey(keyNFTstatus(nftId)) | |
180 | 182 | if (if ((nftStatus == status_LOCKED)) | |
181 | 183 | then true | |
182 | 184 | else (nftStatus == status_PENDING)) | |
183 | 185 | then throw("NFT already locked") | |
184 | 186 | else { | |
185 | 187 | let gasFeeNonMinted = getIntegerByKeyFromOracle(keyFeeNonMinted) | |
186 | 188 | let gasFeeMinted = getIntegerByKeyFromOracle(keyFeeMinted) | |
187 | 189 | let isMinted = if ((nftStatus == status_UNLOCKED)) | |
188 | 190 | then true | |
189 | 191 | else false | |
190 | 192 | if (if (!(isDefined(gateway_payment.assetId))) | |
191 | 193 | then true | |
192 | 194 | else (toBase58String(value(gateway_payment.assetId)) != feeAcceptedAsset)) | |
193 | 195 | then throw("Wrong payment asset") | |
194 | 196 | else if (if (isMinted) | |
195 | - | then (gateway_amount > gasFeeMinted) | |
197 | + | then ((gateway_amount + feeAcceptedAmountForSign) > gasFeeMinted) | |
196 | 198 | else false) | |
197 | 199 | then throw("Wrong payment amount to unlock") | |
198 | 200 | else if (if (!(isMinted)) | |
199 | - | then (gateway_amount > gasFeeNonMinted) | |
201 | + | then ((gateway_amount + feeAcceptedAmountForSign) > gasFeeNonMinted) | |
200 | 202 | else false) | |
201 | 203 | then throw("Wrong payment amount to mint and unlock") | |
202 | 204 | else [StringEntry(keyNFTstatus(nftId), status_PENDING), StringEntry(((keyTransferNFT(nftId, id) + "_") + status_PENDING), ((((((((((((recipient + "_") + network) + "_") + caller) + "_") + id) + "_") + value(assetInfo(value(nft_payment.assetId))).name) + "_") + toString(date)) + "_") + toString(height)))] | |
203 | 205 | } | |
204 | 206 | } | |
205 | 207 | } | |
206 | 208 | } | |
207 | 209 | ||
208 | 210 | ||
209 | 211 | ||
210 | 212 | @Callable(i) | |
211 | 213 | func confirmLock (nftId,transferId) = if (!(isInit)) | |
212 | 214 | then throw("dApp not ready") | |
213 | 215 | else if (ownerOnly(i)) | |
214 | 216 | then { | |
215 | 217 | let nftStatus = getStringByKey(keyNFTstatus(nftId)) | |
216 | 218 | if ((nftStatus != status_PENDING)) | |
217 | 219 | then throw("NFT not pending") | |
218 | 220 | else { | |
219 | 221 | let val = getStringByKey(((keyTransferNFT(nftId, transferId) + "_") + status_PENDING)) | |
220 | 222 | let newKey = ((keyTransferNFT(nftId, transferId) + "_") + status_CLOSED) | |
221 | 223 | [DeleteEntry(((keyTransferNFT(nftId, transferId) + "_") + status_PENDING)), StringEntry(newKey, val), StringEntry(keyNFTstatus(nftId), status_LOCKED)] | |
222 | 224 | } | |
223 | 225 | } | |
224 | 226 | else throw("Not allowed") | |
225 | 227 | ||
226 | 228 | ||
227 | 229 | ||
228 | 230 | @Callable(i) | |
229 | 231 | func unlock (recipient,nftId) = if (!(isInit)) | |
230 | 232 | then throw("dApp not ready") | |
231 | 233 | else if (ownerOnly(i)) | |
232 | 234 | then { | |
233 | 235 | let nftStatus = getStringByKey(keyNFTstatus(nftId)) | |
234 | 236 | if ((nftStatus != status_LOCKED)) | |
235 | 237 | then throw("NFT not locked, finalize first if pending") | |
236 | 238 | else [StringEntry(keyNFTstatus(nftId), status_UNLOCKED), ScriptTransfer(Address(fromBase58String(recipient)), 1, fromBase58String(nftId))] | |
237 | 239 | } | |
238 | 240 | else throw("Not allowed") | |
239 | 241 | ||
240 | 242 | ||
241 | 243 | ||
242 | 244 | @Callable(i) | |
243 | 245 | func appRunning (isLive,message) = if (!(isInit)) | |
244 | 246 | then throw("dApp not ready") | |
245 | 247 | else if (ownerOnly(i)) | |
246 | 248 | then [BooleanEntry(dappRunningKey, isLive), StringEntry(maintenanceMSGKey, message)] | |
247 | 249 | else throw("You are not allowed to change this") | |
248 | 250 | ||
249 | 251 | ||
250 | 252 | ||
251 | 253 | @Callable(i) | |
252 | 254 | func deleteEntry (entry) = if (ownerOnly(i)) | |
253 | 255 | then [DeleteEntry(entry)] | |
254 | 256 | else throw("no") | |
255 | 257 | ||
256 | 258 |
github/deemru/w8io/026f985 38.11 ms ◑