tx · DALUtW1dMsRCquyWm8svBxVim3jk8AkrT2SUyGswHwZM

3NBwZbvD45CscLGF78qTaDRBZ7mDBHt3Yib:  -0.01400000 Waves

2022.09.15 05:25 [2229607] smart account 3NBwZbvD45CscLGF78qTaDRBZ7mDBHt3Yib > SELF 0.00000000 Waves

{ "type": 13, "id": "DALUtW1dMsRCquyWm8svBxVim3jk8AkrT2SUyGswHwZM", "fee": 1400000, "feeAssetId": null, "timestamp": 1663208726745, "version": 2, "chainId": 84, "sender": "3NBwZbvD45CscLGF78qTaDRBZ7mDBHt3Yib", "senderPublicKey": "3q3N8Kv49DbzNHyTB4A87UYz2DdquXCgP3GNCcD9Zj66", "proofs": [ "2GdesypRAWhawd6WPRCCmyNm11j9mrXXiPQZaVcQzYX2RdWxef5bSydCXPf6BP1CxxqAnyM1gNYuSPSJ4wGKDpEK" ], "script": "base64:BgJGCAISDQoLCAgICAgBCAgBAQQSBAoCCAgSBAoCCAESBAoCAQESAwoBBBIECgIICBIFCgMICAgSBAoCCAgSBAoCBAgSAwoBCD0AB3ZlcnNpb24CAzEuMAALQ09ORl9JTklUX0sCC2NvbmZpZ19pbml0AAtDT05GX0FNSU5fSwIMY29uZmlnX2FkbWluAA1DT05GX09SQUNMRV9LAg1jb25maWdfb3JhY2xlABNDT05GX0FSVFdPUktfREFQUF9LAhNjb25maWdfYXJ0d29ya19kYXBwABFDT05GX1VTRVJTX0RBUFBfSwIRY29uZmlnX3VzZXJzX2RhcHAAEENPTkZfRkVFX0FTU0VUX0sCEGNvbmZpZ19mZWVfYXNzZXQAEUNPTkZfRkVFX0FNT1VOVF9LAhFjb25maWdfZmVlX2Ftb3VudAAVQ09ORl9TV09QX1NJR05fREFQUF9LAhVjb25maWdfc3dvcF9zaWduX2RhcHAAFENPTkZfU1dPUF9FVEhfREFQUF9LAhRjb25maWdfc3dvcF9ldGhfZGFwcAAfQ09ORl9DT05GSVJNQVRJT05TX0ZST01fV0FWRVNfSwIfY29uZmlnX2NvbmZpcm1h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ZwIGaXNMaXZlB21lc3NhZ2UDCQEBIQEFBmlzSW5pdAkAAgECDmRBcHAgbm90IHJlYWR5AwkBCW93bmVyT25seQEFAWkJAMwIAgkBDEJvb2xlYW5FbnRyeQIFDWRhcHBSdW5uaW5nX0sFBmlzTGl2ZQkAzAgCCQELU3RyaW5nRW50cnkCBRBtYWludGVuYW5jZU1TR19LBQdtZXNzYWdlBQNuaWwJAAIBAiJZb3UgYXJlIG5vdCBhbGxvd2VkIHRvIGNoYW5nZSB0aGlzAWkBC2RlbGV0ZUVudHJ5AQVlbnRyeQMJAQlvd25lck9ubHkBBQFpCQDMCAIJAQtEZWxldGVFbnRyeQEFBWVudHJ5BQNuaWwJAAIBAgJubwBhC09g", "height": 2229607, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 45Bt8N9suyfqKfoLjzTtKbPAHvzkQ3u9FUH9MKos9dZH Next: Fo8uUoWi1T5j8fvw4nWVEgUnrBf7kyBUD1Um1PmBtAbW Diff:
OldNewDifferences
188188 func setConfirmationsFunc (confirmfromWaves,confirmfromEth) = [IntegerEntry(CONF_CONFIRMATIONS_FROM_WAVES_K, confirmfromWaves), IntegerEntry(CONF_CONFIRMATIONS_FROM_ETH_K, confirmfromEth)]
189189
190190
191-func setAutoSwapFunc (autoswap) = [BooleanEntry(CONF_AUTOSWAP_K, autoswap)]
191+func setAutoswapFeeFunc (autoswapFee) = [BooleanEntry(CONF_AUTOSWAP_K, autoswapFee)]
192192
193193
194194 @Callable(i)
195-func init (adminAddr,oracleAddr,artworksDapp,usersDapp,feeAsset,feeAmount,signDapp,ethDapp,confirmfromWaves,confirmfromEth,autoswap) = if (ownerOnly(i))
195+func init (adminAddr,oracleAddr,artworksDapp,usersDapp,feeAsset,feeAmount,signDapp,ethDapp,confirmfromWaves,confirmfromEth,autoswapFee) = if (ownerOnly(i))
196196 then {
197197 let setSwopDapps = setSwopDappsFunc(signDapp, ethDapp)
198198 let setFee = setFeeFunc(feeAsset, feeAmount)
199199 let setConfirmations = setConfirmationsFunc(confirmfromWaves, confirmfromEth)
200- let setAutoSwap = setAutoSwapFunc(autoswap)
201- (((([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)] ++ setSwopDapps) ++ setFee) ++ setConfirmations) ++ setAutoSwap)
200+ let setAutoswapFee = setAutoswapFeeFunc(autoswapFee)
201+ (((([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)] ++ setSwopDapps) ++ setFee) ++ setConfirmations) ++ setAutoswapFee)
202202 }
203203 else throw("Not allowed")
204204
226226
227227
228228 @Callable(i)
229-func setAutoswap (autoswap) = if (ownerOnly(i))
230- then setAutoSwapFunc(autoswap)
229+func setAutoswapFee (autoswapFee) = if (ownerOnly(i))
230+ then setAutoswapFeeFunc(autoswapFee)
231231 else throw("Not allowed")
232232
233233
240240 else if (!(isEvmAddress(recipient)))
241241 then throw("Wrong recipient address")
242242 else {
243- let $t072127251 = idCallerDate(i)
244- let id = $t072127251._1
245- let caller = $t072127251._2
246- let date = $t072127251._3
247- let $t072547331 = isPayment(i)
248- let nft_payment = $t072547331._1
249- let nft_amount = $t072547331._2
250- let gateway_payment = $t072547331._3
251- let gateway_amount = $t072547331._4
243+ let $t072487287 = idCallerDate(i)
244+ let id = $t072487287._1
245+ let caller = $t072487287._2
246+ let date = $t072487287._3
247+ let $t072907367 = isPayment(i)
248+ let nft_payment = $t072907367._1
249+ let nft_amount = $t072907367._2
250+ let gateway_payment = $t072907367._3
251+ let gateway_amount = $t072907367._4
252252 if ((nft_amount != 1))
253253 then throw("No NFT attached")
254254 else {
257257 else false)
258258 then toBase58String(value(nft_payment.assetId))
259259 else throw("Only SIGN Art NFT accepted.")
260- let $t076187700 = getCreatorFromNFTid(nftId)
261- let creator = $t076187700._1
262- let artId = $t076187700._2
260+ let $t076547736 = getCreatorFromNFTid(nftId)
261+ let creator = $t076547736._1
262+ let artId = $t076547736._2
263263 if (!(isValidCreator(getCreatorStatus(creator))))
264264 then throw(("Creator status is :" + getCreatorStatus(creator)))
265265 else if (!(isValidArt(getArtStatus(artId, creator))))
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let version = "1.0"
55
66 let CONF_INIT_K = "config_init"
77
88 let CONF_AMIN_K = "config_admin"
99
1010 let CONF_ORACLE_K = "config_oracle"
1111
1212 let CONF_ARTWORK_DAPP_K = "config_artwork_dapp"
1313
1414 let CONF_USERS_DAPP_K = "config_users_dapp"
1515
1616 let CONF_FEE_ASSET_K = "config_fee_asset"
1717
1818 let CONF_FEE_AMOUNT_K = "config_fee_amount"
1919
2020 let CONF_SWOP_SIGN_DAPP_K = "config_swop_sign_dapp"
2121
2222 let CONF_SWOP_ETH_DAPP_K = "config_swop_eth_dapp"
2323
2424 let CONF_CONFIRMATIONS_FROM_WAVES_K = "config_confirmations_from_waves"
2525
2626 let CONF_CONFIRMATIONS_FROM_ETH_K = "config_confirmations_from_eth"
2727
2828 let CONF_AUTOSWAP_K = "config_autoswap"
2929
3030 let dappRunning_K = "conf_dapp_is_running"
3131
3232 let maintenanceMSG_K = "conf_maintenance_msg"
3333
3434 let dappRunning = valueOrElse(getBoolean(this, dappRunning_K), true)
3535
3636 let maintenanceMSG = valueOrElse(getString(this, maintenanceMSG_K), "")
3737
3838 let status_LOCKED = "LOCKED"
3939
4040 let status_UNLOCKED = "UNLOCKED"
4141
4242 let status_PENDING = "PENDING"
4343
4444 let status_CLOSED = "CLOSED"
4545
4646 let creatorRegistered = "REGISTERED"
4747
4848 let creatorVerified = "VERIFIED"
4949
5050 let artFlagged = "FLAGGED"
5151
5252 let artIllegal = "ILLEGAL"
5353
5454 let artPending = "CHANGE_REQUIRED"
5555
5656 let NETWORKS = ["ETH"]
5757
5858 func keyNFTstatus (nftId) = (("nft_" + nftId) + "_status")
5959
6060
6161 func keyTransferNFT (nftId,txid,caller) = ((((("transfer_" + nftId) + "_") + txid) + "_") + caller)
6262
6363
6464 let keyFeeNonMinted = "cost_non_minted"
6565
6666 let keyFeeMinted = "cost_minted"
6767
6868 func getStringByKey (key) = valueOrElse(getString(this, key), "")
6969
7070
7171 func getIntegerByKey (key) = valueOrElse(getInteger(this, key), 0)
7272
7373
7474 func getBooleanByKey (key) = valueOrElse(getBoolean(this, key), false)
7575
7676
7777 let admin = value(addressFromStringValue(getStringByKey(CONF_AMIN_K)))
7878
7979 let artworksDapp = value(addressFromString(getStringByKey(CONF_ARTWORK_DAPP_K)))
8080
8181 let usersDapp = value(addressFromString(getStringByKey(CONF_USERS_DAPP_K)))
8282
8383 let oracleAddr = value(addressFromString(getStringByKey(CONF_ORACLE_K)))
8484
8585 let autoswap = valueOrElse(getBooleanByKey(CONF_AUTOSWAP_K), false)
8686
8787 let feeAcceptedAsset = getStringByKey(CONF_FEE_ASSET_K)
8888
8989 let feeAcceptedAmountForSign = getIntegerByKey(CONF_FEE_AMOUNT_K)
9090
9191 func getStringFromUsersByKey (key) = valueOrElse(getString(usersDapp, key), "")
9292
9393
9494 func getStringFromArtworksByKey (key) = valueOrElse(getString(artworksDapp, key), "")
9595
9696
9797 func getIntegerByKeyFromOracle (key) = valueOrErrorMessage(getInteger(oracleAddr, key), "Integer undefined in oracle")
9898
9999
100100 func assetIsValid (assetDetails) = if (if (if ((assetDetails.quantity == 1))
101101 then (assetDetails.decimals == 0)
102102 else false)
103103 then (assetDetails.reissuable == false)
104104 else false)
105105 then (assetDetails.issuer == artworksDapp)
106106 else false
107107
108108
109109 func isSignArtNFT (id) = {
110110 let assetDetails = value(assetInfo(id))
111111 assetIsValid(assetDetails)
112112 }
113113
114114
115115 func isPayment (i) = if ((size(i.payments) != 2))
116116 then throw("Need to attach 2 payments")
117117 else {
118118 let nft_payment = value(i.payments[0])
119119 let nft_amount = value(nft_payment.amount)
120120 let gateway_payment = value(i.payments[1])
121121 let gateway_amount = value(gateway_payment.amount)
122122 $Tuple4(nft_payment, nft_amount, gateway_payment, gateway_amount)
123123 }
124124
125125
126126 let isInit = valueOrElse(getBooleanByKey(CONF_INIT_K), false)
127127
128128 func ownerOnly (i) = {
129129 let caller = toString(i.caller)
130130 let id = toBase58String(i.transactionId)
131131 let allowedArr = if (isInit)
132132 then [toString(admin), toString(this)]
133133 else [toString(this)]
134134 containsElement(allowedArr, caller)
135135 }
136136
137137
138138 func idCallerDate (i) = if (!(dappRunning))
139139 then throw(maintenanceMSG)
140140 else $Tuple3(toBase58String(i.transactionId), toBase58String(i.caller.bytes), lastBlock.timestamp)
141141
142142
143143 func getCreatorFromNFTid (nftid) = {
144144 let nftData = getStringFromArtworksByKey(("nft_" + nftid))
145145 let creator = split(nftData, "_")[6]
146146 let artId = split(nftData, "_")[5]
147147 $Tuple2(creator, artId)
148148 }
149149
150150
151151 func getCreatorERC20Addr (addr) = getStringFromUsersByKey(("user_ERC20_" + addr))
152152
153153
154154 func getCreatorStatus (addr) = getStringFromUsersByKey(("user_status_" + addr))
155155
156156
157157 func getArtStatus (artId,addr) = getStringFromArtworksByKey(((("art_flag_" + artId) + "_") + addr))
158158
159159
160160 func isValidCreator (status) = if ((status == creatorRegistered))
161161 then true
162162 else (status == creatorVerified)
163163
164164
165165 func isValidArt (status) = if (if ((status != artFlagged))
166166 then (status != artIllegal)
167167 else false)
168168 then (status != artPending)
169169 else false
170170
171171
172172 func isEvmAddress (addr) = if ((size(addr) == 42))
173173 then (take(addr, 2) == "0x")
174174 else false
175175
176176
177177 func setSwopDappsFunc (signDapp,ethDapp) = [StringEntry(CONF_SWOP_SIGN_DAPP_K, signDapp), StringEntry(CONF_SWOP_ETH_DAPP_K, ethDapp)]
178178
179179
180180 func setFeeFunc (feeAsset,feeAmount) = {
181181 let assetDetails = assetInfo(fromBase58String(feeAsset))
182182 let decimal = value(assetDetails).decimals
183183 let base10FeeAmount = pow(feeAmount, 0, 10, 1, decimal, HALFUP)
184184 [StringEntry(CONF_FEE_ASSET_K, feeAsset), IntegerEntry(CONF_FEE_AMOUNT_K, base10FeeAmount)]
185185 }
186186
187187
188188 func setConfirmationsFunc (confirmfromWaves,confirmfromEth) = [IntegerEntry(CONF_CONFIRMATIONS_FROM_WAVES_K, confirmfromWaves), IntegerEntry(CONF_CONFIRMATIONS_FROM_ETH_K, confirmfromEth)]
189189
190190
191-func setAutoSwapFunc (autoswap) = [BooleanEntry(CONF_AUTOSWAP_K, autoswap)]
191+func setAutoswapFeeFunc (autoswapFee) = [BooleanEntry(CONF_AUTOSWAP_K, autoswapFee)]
192192
193193
194194 @Callable(i)
195-func init (adminAddr,oracleAddr,artworksDapp,usersDapp,feeAsset,feeAmount,signDapp,ethDapp,confirmfromWaves,confirmfromEth,autoswap) = if (ownerOnly(i))
195+func init (adminAddr,oracleAddr,artworksDapp,usersDapp,feeAsset,feeAmount,signDapp,ethDapp,confirmfromWaves,confirmfromEth,autoswapFee) = if (ownerOnly(i))
196196 then {
197197 let setSwopDapps = setSwopDappsFunc(signDapp, ethDapp)
198198 let setFee = setFeeFunc(feeAsset, feeAmount)
199199 let setConfirmations = setConfirmationsFunc(confirmfromWaves, confirmfromEth)
200- let setAutoSwap = setAutoSwapFunc(autoswap)
201- (((([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)] ++ setSwopDapps) ++ setFee) ++ setConfirmations) ++ setAutoSwap)
200+ let setAutoswapFee = setAutoswapFeeFunc(autoswapFee)
201+ (((([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)] ++ setSwopDapps) ++ setFee) ++ setConfirmations) ++ setAutoswapFee)
202202 }
203203 else throw("Not allowed")
204204
205205
206206
207207 @Callable(i)
208208 func setSwopDapps (signDapp,ethDapp) = if (ownerOnly(i))
209209 then setSwopDappsFunc(signDapp, ethDapp)
210210 else throw("Not allowed")
211211
212212
213213
214214 @Callable(i)
215215 func setFee (feeAsset,feeAmount) = if (ownerOnly(i))
216216 then setFeeFunc(feeAsset, feeAmount)
217217 else throw("Not allowed")
218218
219219
220220
221221 @Callable(i)
222222 func setConfirmations (confirmfromWaves,confirmfromEth) = if (ownerOnly(i))
223223 then setConfirmationsFunc(confirmfromWaves, confirmfromEth)
224224 else throw("Not allowed")
225225
226226
227227
228228 @Callable(i)
229-func setAutoswap (autoswap) = if (ownerOnly(i))
230- then setAutoSwapFunc(autoswap)
229+func setAutoswapFee (autoswapFee) = if (ownerOnly(i))
230+ then setAutoswapFeeFunc(autoswapFee)
231231 else throw("Not allowed")
232232
233233
234234
235235 @Callable(i)
236236 func lock (recipient,network) = if (!(isInit))
237237 then throw("dApp not ready")
238238 else if (!(containsElement(NETWORKS, network)))
239239 then throw("Network not supported")
240240 else if (!(isEvmAddress(recipient)))
241241 then throw("Wrong recipient address")
242242 else {
243- let $t072127251 = idCallerDate(i)
244- let id = $t072127251._1
245- let caller = $t072127251._2
246- let date = $t072127251._3
247- let $t072547331 = isPayment(i)
248- let nft_payment = $t072547331._1
249- let nft_amount = $t072547331._2
250- let gateway_payment = $t072547331._3
251- let gateway_amount = $t072547331._4
243+ let $t072487287 = idCallerDate(i)
244+ let id = $t072487287._1
245+ let caller = $t072487287._2
246+ let date = $t072487287._3
247+ let $t072907367 = isPayment(i)
248+ let nft_payment = $t072907367._1
249+ let nft_amount = $t072907367._2
250+ let gateway_payment = $t072907367._3
251+ let gateway_amount = $t072907367._4
252252 if ((nft_amount != 1))
253253 then throw("No NFT attached")
254254 else {
255255 let nftId = if (if (isDefined(nft_payment.assetId))
256256 then isSignArtNFT(value(nft_payment.assetId))
257257 else false)
258258 then toBase58String(value(nft_payment.assetId))
259259 else throw("Only SIGN Art NFT accepted.")
260- let $t076187700 = getCreatorFromNFTid(nftId)
261- let creator = $t076187700._1
262- let artId = $t076187700._2
260+ let $t076547736 = getCreatorFromNFTid(nftId)
261+ let creator = $t076547736._1
262+ let artId = $t076547736._2
263263 if (!(isValidCreator(getCreatorStatus(creator))))
264264 then throw(("Creator status is :" + getCreatorStatus(creator)))
265265 else if (!(isValidArt(getArtStatus(artId, creator))))
266266 then throw(("Artwork status is :" + getArtStatus(artId, creator)))
267267 else {
268268 let erc20Addr = getCreatorERC20Addr(creator)
269269 if ((size(erc20Addr) == 0))
270270 then throw("This artist didn't allow crosschain transfer")
271271 else {
272272 let nftStatus = getStringByKey(keyNFTstatus(nftId))
273273 if (if ((nftStatus == status_LOCKED))
274274 then true
275275 else (nftStatus == status_PENDING))
276276 then throw("NFT already locked")
277277 else {
278278 let gasFeeNonMinted = getIntegerByKeyFromOracle(keyFeeNonMinted)
279279 let gasFeeMinted = getIntegerByKeyFromOracle(keyFeeMinted)
280280 let isMinted = if ((nftStatus == status_UNLOCKED))
281281 then true
282282 else false
283283 if (if (!(isDefined(gateway_payment.assetId)))
284284 then true
285285 else (toBase58String(value(gateway_payment.assetId)) != feeAcceptedAsset))
286286 then throw("Wrong payment asset")
287287 else if (if (isMinted)
288288 then (gateway_amount > (gasFeeMinted + feeAcceptedAmountForSign))
289289 else false)
290290 then throw("Wrong payment amount to unlock")
291291 else if (if (!(isMinted))
292292 then (gateway_amount > (gasFeeNonMinted + feeAcceptedAmountForSign))
293293 else false)
294294 then throw("Wrong payment amount to mint and unlock")
295295 else {
296296 let usdnToSwapForEth = if (isMinted)
297297 then gasFeeMinted
298298 else gasFeeNonMinted
299299 let swap_usdn_to_sign = if (autoswap)
300300 then invoke(addressFromStringValue(getStringByKey(CONF_SWOP_SIGN_DAPP_K)), "exchange", [1], [AttachedPayment(fromBase58String(feeAcceptedAsset), feeAcceptedAmountForSign)])
301301 else unit
302302 if ((swap_usdn_to_sign == swap_usdn_to_sign))
303303 then {
304304 let swap_usdn_to_eth = if (autoswap)
305305 then invoke(addressFromStringValue(getStringByKey(CONF_SWOP_ETH_DAPP_K)), "exchange", [1], [AttachedPayment(fromBase58String(feeAcceptedAsset), usdnToSwapForEth)])
306306 else unit
307307 if ((swap_usdn_to_eth == swap_usdn_to_eth))
308308 then [StringEntry(keyNFTstatus(nftId), status_PENDING), StringEntry(((keyTransferNFT(nftId, id, caller) + "_") + status_PENDING), ((((((((((((recipient + "_") + network) + "_") + caller) + "_") + id) + "_") + value(assetInfo(value(nft_payment.assetId))).name) + "_") + toString(date)) + "_") + toString(height)))]
309309 else throw("Strict value is not equal to itself.")
310310 }
311311 else throw("Strict value is not equal to itself.")
312312 }
313313 }
314314 }
315315 }
316316 }
317317 }
318318
319319
320320
321321 @Callable(i)
322322 func confirmLock (nftId,transferId,caller) = if (!(isInit))
323323 then throw("dApp not ready")
324324 else if (ownerOnly(i))
325325 then {
326326 let nftStatus = getStringByKey(keyNFTstatus(nftId))
327327 if ((nftStatus != status_PENDING))
328328 then throw("NFT not pending")
329329 else {
330330 let val = getStringByKey(((keyTransferNFT(nftId, transferId, caller) + "_") + status_PENDING))
331331 let newKey = ((keyTransferNFT(nftId, transferId, caller) + "_") + status_CLOSED)
332332 [DeleteEntry(((keyTransferNFT(nftId, transferId, caller) + "_") + status_PENDING)), StringEntry(newKey, val), StringEntry(keyNFTstatus(nftId), status_LOCKED)]
333333 }
334334 }
335335 else throw("Not allowed")
336336
337337
338338
339339 @Callable(i)
340340 func unlock (recipient,nftId) = if (!(isInit))
341341 then throw("dApp not ready")
342342 else if (ownerOnly(i))
343343 then {
344344 let nftStatus = getStringByKey(keyNFTstatus(nftId))
345345 if ((nftStatus != status_LOCKED))
346346 then throw("NFT not locked, finalize first if pending")
347347 else [StringEntry(keyNFTstatus(nftId), status_UNLOCKED), ScriptTransfer(Address(fromBase58String(recipient)), 1, fromBase58String(nftId))]
348348 }
349349 else throw("Not allowed")
350350
351351
352352
353353 @Callable(i)
354354 func appRunning (isLive,message) = if (!(isInit))
355355 then throw("dApp not ready")
356356 else if (ownerOnly(i))
357357 then [BooleanEntry(dappRunning_K, isLive), StringEntry(maintenanceMSG_K, message)]
358358 else throw("You are not allowed to change this")
359359
360360
361361
362362 @Callable(i)
363363 func deleteEntry (entry) = if (ownerOnly(i))
364364 then [DeleteEntry(entry)]
365365 else throw("no")
366366
367367

github/deemru/w8io/026f985 
54.60 ms