tx · CRvKzGEymcewArLXX3WBr8mbTUkgsL4zqwKiTefCUZ7m 3N2eA4yzXa4wTj7pP8r6G144RRxZW7cmq4p: -0.01400000 Waves 2022.01.27 13:01 [1897218] smart account 3N2eA4yzXa4wTj7pP8r6G144RRxZW7cmq4p > SELF 0.00000000 Waves
{ "type": 13, "id": "CRvKzGEymcewArLXX3WBr8mbTUkgsL4zqwKiTefCUZ7m", "fee": 1400000, "feeAssetId": null, "timestamp": 1643277722400, "version": 2, "chainId": 84, "sender": "3N2eA4yzXa4wTj7pP8r6G144RRxZW7cmq4p", "senderPublicKey": "Hh3eFP2XFetZSfTxQiM1Ps96f68zi8Zh5ghhCZdjgdFs", "proofs": [ "3qySYesk3zaDrs78GqRtZNWNmRVsHx14jZeagf3gFcFCwGCX6oHVrF2qNPXbrCF3YFpA9bk7NGH8UyUN6GCdjw5H" ], "script": "base64:AAIFAAAAAAAAADIIAhIECgIECBIECgIBCBIFCgMIAQgSAwoBCBIDCgEIEgMKAQgSBQoDCAgIEgUKAwgICAAAADMAAAAACHVuaXRUZXN0BwAAAAAJb3JhY2xlRmVlCQEAAAAFdmFsdWUAAAABCQAEJgAAAAECAAAAIzNOMnM1UnRhSFBCZW5Dc3gyRUNjb0ZSYllIeDNub1poWFcxAAAAAAhzaWduRGFwcAkBAAAABXZhbHVlAAAAAQkABCYAAAABAgAAACMzTkMyOGhTaXZybXNUVVhhWUQxeDZMMzYySjRacFVub1RkQgAAAAAMYXJ0d29ya3NEYXBwCQEAAAAFdmFsdWUAAAABCQAEJgAAAAECAAAAIzNOQnluZmJYQzJLYXN0VXhodWtjTVVhRTU4SzljQmRCOVVZAAAAAAtmZWVSZWNlaXZlcgIAAAAjM04xRTZ0WGRkUm9WYVJmUTlkUTN2ZzVMYVcyZnNkOEhLdWIAAAAACHVzZXJEYXBwAwUAAAAIdW5pdFRlc3QJAQAAAAV2YWx1ZQAAAAEJAAQmAAAAAQIAAAAjM010NFJHTUV5alNXWUFvY1RQcWQ1NXdk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KYmlkRGF0YUFycggFAAAADSR0MDE3MTM0MTcxODkAAAACXzEEAAAAB2Fzc2V0SWQIBQAAAA0kdDAxNzEzNDE3MTg5AAAAAl8yBAAAAAdiaWREYXRhCAUAAAANJHQwMTcxMzQxNzE4OQAAAAJfMwkABEwAAAACCQEAAAALRGVsZXRlRW50cnkAAAABCQABLAAAAAIFAAAABmJpZEtleQIAAAAFX09QRU4JAARMAAAAAgkBAAAAC1N0cmluZ0VudHJ5AAAAAgkAASwAAAACBQAAAAZiaWRLZXkCAAAACl9DQU5DRUxMRUQJAAEsAAAAAgkAASwAAAACCQABLAAAAAIJAAEsAAAAAgUAAAAHYmlkRGF0YQIAAAALX0NBTkNFTExFRF8JAAGkAAAAAQUAAAAEZGF0ZQIAAAABXwUAAAACaWQJAARMAAAAAgkBAAAADlNjcmlwdFRyYW5zZmVyAAAAAwkBAAAAB0FkZHJlc3MAAAABCQACWQAAAAEFAAAABmNhbGxlcgkBAAAADXBhcnNlSW50VmFsdWUAAAABCQABkQAAAAIFAAAACmJpZERhdGFBcnIAAAAAAAAAAAEFAAAAB2Fzc2V0SWQFAAAAA25pbAAAAAD9MBnf", "height": 1897218, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: BYfHbe3ZnUDTCmJvdv1kjEf2dB7skXZi4q3KRrm9kBMV Next: 2GSszNH86LhfLoYyqTX1i7Jg6qJ751hHq2M1SBWh5cY5 Diff:
Old | New | Differences | |
---|---|---|---|
241 | 241 | ||
242 | 242 | ||
243 | 243 | func provideBaseData (i,nftId) = { | |
244 | - | let $ | |
245 | - | let id = $ | |
246 | - | let caller = $ | |
247 | - | let date = $ | |
248 | - | let $ | |
249 | - | let isValidNFT = $ | |
250 | - | let artId = $ | |
251 | - | let creatorAddr = $ | |
252 | - | let artSignID = $ | |
244 | + | let $t085778616 = idCallerDate(i) | |
245 | + | let id = $t085778616._1 | |
246 | + | let caller = $t085778616._2 | |
247 | + | let date = $t085778616._3 | |
248 | + | let $t086198688 = checkNFTInfo(nftId) | |
249 | + | let isValidNFT = $t086198688._1 | |
250 | + | let artId = $t086198688._2 | |
251 | + | let creatorAddr = $t086198688._3 | |
252 | + | let artSignID = $t086198688._4 | |
253 | 253 | $Tuple7(id, caller, date, isValidNFT, artId, creatorAddr, artSignID) | |
254 | 254 | } | |
255 | 255 | ||
273 | 273 | ||
274 | 274 | @Callable(i) | |
275 | 275 | func sellNFT (price,asset) = { | |
276 | - | let $ | |
277 | - | let payment = $ | |
278 | - | let amount = $ | |
276 | + | let $t094019437 = isPayment(i) | |
277 | + | let payment = $t094019437._1 | |
278 | + | let amount = $t094019437._2 | |
279 | 279 | let nftId = if (if (isDefined(payment.assetId)) | |
280 | 280 | then isSignArtNFT(value(payment.assetId)) | |
281 | 281 | else false) | |
282 | 282 | then toBase58String(value(payment.assetId)) | |
283 | 283 | else throw("Only SIGN Art NFT accepted.") | |
284 | - | let $ | |
285 | - | let id = $ | |
286 | - | let caller = $ | |
287 | - | let date = $ | |
288 | - | let isValidNFT = $ | |
289 | - | let artId = $ | |
290 | - | let creatorAddr = $ | |
291 | - | let artSignID = $ | |
284 | + | let $t096169708 = provideBaseData(i, nftId) | |
285 | + | let id = $t096169708._1 | |
286 | + | let caller = $t096169708._2 | |
287 | + | let date = $t096169708._3 | |
288 | + | let isValidNFT = $t096169708._4 | |
289 | + | let artId = $t096169708._5 | |
290 | + | let creatorAddr = $t096169708._6 | |
291 | + | let artSignID = $t096169708._7 | |
292 | 292 | if ((size(artSignID) == 0)) | |
293 | 293 | then throw("Artwork not found on SIGN Art") | |
294 | 294 | else if (!(isValidNFT)) | |
295 | 295 | then throw("Not a valid nft") | |
296 | 296 | else if (!(acceptedAssetIds(asset))) | |
297 | 297 | then throw("Only SIGN, USDN or WAVES accepted") | |
298 | - | else if ((price | |
298 | + | else if (!(validateMinSell(asset, price))) | |
299 | 299 | then throw("Wrong minimum sell price") | |
300 | - | else if (!(validateMinSell(asset, price))) | |
301 | - | then throw("Wrong minimum sell price") | |
302 | - | else [StringEntry((getSaleKey(caller, nftId, artId, creatorAddr) + "_OPEN"), ((((((((((((toString(date) + "_") + toString(price)) + "_") + asset) + "_") + nftId) + "_") + artId) + "_") + creatorAddr) + "_") + id)), StringEntry(((("sale2nd_status_" + caller) + "_") + nftId), "OPEN"), StringEntry(("current_owner_on_dapp_" + nftId), caller)] | |
300 | + | else [StringEntry((getSaleKey(caller, nftId, artId, creatorAddr) + "_OPEN"), ((((((((((((toString(date) + "_") + toString(price)) + "_") + asset) + "_") + nftId) + "_") + artId) + "_") + creatorAddr) + "_") + id)), StringEntry(((("sale2nd_status_" + caller) + "_") + nftId), "OPEN"), StringEntry(("current_owner_on_dapp_" + nftId), caller)] | |
303 | 301 | } | |
304 | 302 | ||
305 | 303 | ||
306 | 304 | ||
307 | 305 | @Callable(i) | |
308 | 306 | func updateSalePrice (nftId,price,asset) = { | |
309 | - | let $ | |
310 | - | let id = $ | |
311 | - | let caller = $ | |
312 | - | let date = $ | |
313 | - | let isValidNFT = $ | |
314 | - | let artId = $ | |
315 | - | let creatorAddr = $ | |
316 | - | let artSignID = $ | |
307 | + | let $t01058210674 = provideBaseData(i, nftId) | |
308 | + | let id = $t01058210674._1 | |
309 | + | let caller = $t01058210674._2 | |
310 | + | let date = $t01058210674._3 | |
311 | + | let isValidNFT = $t01058210674._4 | |
312 | + | let artId = $t01058210674._5 | |
313 | + | let creatorAddr = $t01058210674._6 | |
314 | + | let artSignID = $t01058210674._7 | |
317 | 315 | if ((size(artSignID) == 0)) | |
318 | 316 | then throw("Artwork not found on SIGN Art, cancel your sale.") | |
319 | 317 | else if (!(isValidNFT)) | |
345 | 343 | ||
346 | 344 | @Callable(i) | |
347 | 345 | func cancelSale (nftId) = { | |
348 | - | let $ | |
349 | - | let id = $ | |
350 | - | let caller = $ | |
351 | - | let date = $ | |
352 | - | let isValidNFT = $ | |
353 | - | let artId = $ | |
354 | - | let creatorAddr = $ | |
355 | - | let artSignID = $ | |
346 | + | let $t01181412054 = provideBaseData(i, nftId) | |
347 | + | let id = $t01181412054._1 | |
348 | + | let caller = $t01181412054._2 | |
349 | + | let date = $t01181412054._3 | |
350 | + | let isValidNFT = $t01181412054._4 | |
351 | + | let artId = $t01181412054._5 | |
352 | + | let creatorAddr = $t01181412054._6 | |
353 | + | let artSignID = $t01181412054._7 | |
356 | 354 | let saleOwner = getStrByK(("current_owner_on_dapp_" + nftId)) | |
357 | 355 | if ((saleOwner != caller)) | |
358 | 356 | then throw("You don't own this NFT") | |
372 | 370 | ||
373 | 371 | @Callable(i) | |
374 | 372 | func buyNFT (nftId) = { | |
375 | - | let $ | |
376 | - | let id = $ | |
377 | - | let caller = $ | |
378 | - | let date = $ | |
379 | - | let isValidNFT = $ | |
380 | - | let artId = $ | |
381 | - | let creatorAddr = $ | |
382 | - | let artSignID = $ | |
373 | + | let $t01288512977 = provideBaseData(i, nftId) | |
374 | + | let id = $t01288512977._1 | |
375 | + | let caller = $t01288512977._2 | |
376 | + | let date = $t01288512977._3 | |
377 | + | let isValidNFT = $t01288512977._4 | |
378 | + | let artId = $t01288512977._5 | |
379 | + | let creatorAddr = $t01288512977._6 | |
380 | + | let artSignID = $t01288512977._7 | |
383 | 381 | if ((size(artSignID) == 0)) | |
384 | 382 | then throw("Artwork not found on SIGN Art, cancel your sale.") | |
385 | 383 | else if (!(isValidNFT)) | |
395 | 393 | if ((parseInt(saleInfoArray[1]) == 0)) | |
396 | 394 | then throw("Offer only") | |
397 | 395 | else { | |
398 | - | let $ | |
399 | - | let payment = $ | |
400 | - | let amount = $ | |
396 | + | let $t01347413510 = isPayment(i) | |
397 | + | let payment = $t01347413510._1 | |
398 | + | let amount = $t01347413510._2 | |
401 | 399 | let paymentAssetStr = if (isDefined(payment.assetId)) | |
402 | 400 | then toBase58String(value(payment.assetId)) | |
403 | 401 | else "" | |
409 | 407 | let amountForSign = fraction(amount, signCut, 100) | |
410 | 408 | let amountForCreator = fraction(amount, creatorCut, 100) | |
411 | 409 | let amountForOwner = (amount - (amountForSign + amountForCreator)) | |
412 | - | let $ | |
413 | - | let signFee = $ | |
414 | - | let creatorFee = $ | |
415 | - | let ownerFee = $ | |
416 | - | let collectorNFT = $ | |
410 | + | let $t01401314141 = setTransfers(amount, payment.assetId, nftId, creatorAddr, saleOwner, caller) | |
411 | + | let signFee = $t01401314141._1 | |
412 | + | let creatorFee = $t01401314141._2 | |
413 | + | let ownerFee = $t01401314141._3 | |
414 | + | let collectorNFT = $t01401314141._4 | |
417 | 415 | [DeleteEntry((saleKey + "_OPEN")), DeleteEntry(((("sale2nd_status_" + saleOwner) + "_") + nftId)), DeleteEntry(("current_owner_on_dapp_" + nftId)), StringEntry((((saleKey + "_") + id) + "_CLOSED"), ((((((saleInfo + "_CLOSED_") + toString(date)) + "_") + id) + "_") + caller)), updateNumSales(), signFee, creatorFee, ownerFee, collectorNFT] | |
418 | 416 | } | |
419 | 417 | } | |
425 | 423 | ||
426 | 424 | @Callable(i) | |
427 | 425 | func setOffer (nftId) = { | |
428 | - | let $ | |
429 | - | let id = $ | |
430 | - | let offerOwner = $ | |
431 | - | let date = $ | |
432 | - | let isValidNFT = $ | |
433 | - | let artId = $ | |
434 | - | let creatorAddr = $ | |
435 | - | let artSignID = $ | |
426 | + | let $t01454914645 = provideBaseData(i, nftId) | |
427 | + | let id = $t01454914645._1 | |
428 | + | let offerOwner = $t01454914645._2 | |
429 | + | let date = $t01454914645._3 | |
430 | + | let isValidNFT = $t01454914645._4 | |
431 | + | let artId = $t01454914645._5 | |
432 | + | let creatorAddr = $t01454914645._6 | |
433 | + | let artSignID = $t01454914645._7 | |
436 | 434 | if (!(isValidNFT)) | |
437 | 435 | then throw("Not a valid nft") | |
438 | 436 | else { | |
439 | - | let $ | |
440 | - | let payment = $ | |
441 | - | let amount = $ | |
437 | + | let $t01470614742 = isPayment(i) | |
438 | + | let payment = $t01470614742._1 | |
439 | + | let amount = $t01470614742._2 | |
442 | 440 | let assetId = if (!(isDefined(payment.assetId))) | |
443 | 441 | then "WAVES" | |
444 | 442 | else toBase58String(value(payment.assetId)) | |
459 | 457 | ||
460 | 458 | @Callable(i) | |
461 | 459 | func acceptOffer (nftId,offerId,offerOwner) = { | |
462 | - | let $ | |
463 | - | let id = $ | |
464 | - | let caller = $ | |
465 | - | let date = $ | |
466 | - | let isValidNFT = $ | |
467 | - | let artId = $ | |
468 | - | let creatorAddr = $ | |
469 | - | let artSignID = $ | |
460 | + | let $t01554415636 = provideBaseData(i, nftId) | |
461 | + | let id = $t01554415636._1 | |
462 | + | let caller = $t01554415636._2 | |
463 | + | let date = $t01554415636._3 | |
464 | + | let isValidNFT = $t01554415636._4 | |
465 | + | let artId = $t01554415636._5 | |
466 | + | let creatorAddr = $t01554415636._6 | |
467 | + | let artSignID = $t01554415636._7 | |
470 | 468 | if (!(isValidNFT)) | |
471 | 469 | then throw("Not a valid nft") | |
472 | 470 | else { | |
475 | 473 | then throw("Only sale owner can accept offer") | |
476 | 474 | else { | |
477 | 475 | let bidKey = getBidKey(offerOwner, nftId, saleOwner, offerId) | |
478 | - | let $ | |
479 | - | let bidDataArr = $ | |
480 | - | let assetId = $ | |
481 | - | let bidData = $ | |
476 | + | let $t01589015945 = getBidData(bidKey) | |
477 | + | let bidDataArr = $t01589015945._1 | |
478 | + | let assetId = $t01589015945._2 | |
479 | + | let bidData = $t01589015945._3 | |
482 | 480 | let saleKey = getSaleKey(saleOwner, nftId, artId, creatorAddr) | |
483 | 481 | let saleInfo = getStrByK((saleKey + "_OPEN")) | |
484 | 482 | if ((size(saleInfo) == 0)) | |
485 | 483 | then throw("Sale Not found!") | |
486 | 484 | else { | |
487 | 485 | let amount = value(parseInt(bidDataArr[1])) | |
488 | - | let $ | |
489 | - | let signFee = $ | |
490 | - | let creatorFee = $ | |
491 | - | let ownerFee = $ | |
492 | - | let collectorNFT = $ | |
486 | + | let $t01617716304 = setTransfers(amount, assetId, nftId, creatorAddr, saleOwner, bidDataArr[6]) | |
487 | + | let signFee = $t01617716304._1 | |
488 | + | let creatorFee = $t01617716304._2 | |
489 | + | let ownerFee = $t01617716304._3 | |
490 | + | let collectorNFT = $t01617716304._4 | |
493 | 491 | [DeleteEntry((saleKey + "_OPEN")), DeleteEntry((bidKey + "_OPEN")), DeleteEntry(((("sale2nd_status_" + saleOwner) + "_") + nftId)), DeleteEntry(("current_owner_on_dapp_" + nftId)), StringEntry((bidKey + "_CLOSED"), ((((bidData + "_CLOSED_") + toString(date)) + "_") + id)), StringEntry((((saleKey + "_") + id) + "_CLOSED"), ((((((((((saleInfo + "_CLOSED-OFFER_") + toString(date)) + "_") + id) + "_") + offerOwner) + "_") + toString(amount)) + "_") + toBase58String(value(assetId)))), updateNumSales(), signFee, creatorFee, ownerFee, collectorNFT] | |
494 | 492 | } | |
495 | 493 | } | |
500 | 498 | ||
501 | 499 | @Callable(i) | |
502 | 500 | func cancelOffer (nftId,offerId,saleOwner) = { | |
503 | - | let $ | |
504 | - | let id = $ | |
505 | - | let caller = $ | |
506 | - | let date = $ | |
501 | + | let $t01700917070 = idCallerDate(i) | |
502 | + | let id = $t01700917070._1 | |
503 | + | let caller = $t01700917070._2 | |
504 | + | let date = $t01700917070._3 | |
507 | 505 | let bidKey = getBidKey(caller, nftId, saleOwner, offerId) | |
508 | - | let $ | |
509 | - | let bidDataArr = $ | |
510 | - | let assetId = $ | |
511 | - | let bidData = $ | |
506 | + | let $t01713417189 = getBidData(bidKey) | |
507 | + | let bidDataArr = $t01713417189._1 | |
508 | + | let assetId = $t01713417189._2 | |
509 | + | let bidData = $t01713417189._3 | |
512 | 510 | [DeleteEntry((bidKey + "_OPEN")), StringEntry((bidKey + "_CANCELLED"), ((((bidData + "_CANCELLED_") + toString(date)) + "_") + id)), ScriptTransfer(Address(fromBase58String(caller)), parseIntValue(bidDataArr[1]), assetId)] | |
513 | 511 | } | |
514 | 512 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let unitTest = false | |
5 | 5 | ||
6 | 6 | let oracleFee = value(addressFromString("3N2s5RtaHPBenCsx2ECcoFRbYHx3noZhXW1")) | |
7 | 7 | ||
8 | 8 | let signDapp = value(addressFromString("3NC28hSivrmsTUXaYD1x6L362J4ZpUnoTdB")) | |
9 | 9 | ||
10 | 10 | let artworksDapp = value(addressFromString("3NBynfbXC2KastUxhukcMUaE58K9cBdB9UY")) | |
11 | 11 | ||
12 | 12 | let feeReceiver = "3N1E6tXddRoVaRfQ9dQ3vg5LaW2fsd8HKub" | |
13 | 13 | ||
14 | 14 | let userDapp = if (unitTest) | |
15 | 15 | then value(addressFromString("3Mt4RGMEyjSWYAocTPqd55wdHQQB3PU2UCm")) | |
16 | 16 | else value(addressFromString("3N8xXaYjE27Aa79d5hHrhHu9HaFoTBmhDEj")) | |
17 | 17 | ||
18 | 18 | let whitelistDapp = value(addressFromString("3N6BaV1dCB4zg43goNNHaCtvR13BcyJ5Gsq")) | |
19 | 19 | ||
20 | 20 | let signAssetId = base58'Gf9t8FA4H3ssoZPCwrg3KwUFCci8zuUFP9ssRsUY3s6a' | |
21 | 21 | ||
22 | 22 | let usdnAssetId = base58'25FEqEjRkqK6yCkiT7Lz6SAYz7gUFCtxfCChnrVFD5AT' | |
23 | 23 | ||
24 | 24 | let wavesAssetId = base58'' | |
25 | 25 | ||
26 | 26 | let chris = "3MsG6jPNCrVJUtYB7XJBxS7utWsXAf4n9Vp" | |
27 | 27 | ||
28 | 28 | let signCut = 3 | |
29 | 29 | ||
30 | 30 | let creatorCut = 10 | |
31 | 31 | ||
32 | 32 | let userSuspended = "SUSPENDED" | |
33 | 33 | ||
34 | 34 | let userRemoved = "REMOVED" | |
35 | 35 | ||
36 | 36 | let artIllegal = "ILLEGAL" | |
37 | 37 | ||
38 | 38 | let artSuspended = "SUSPENDED" | |
39 | 39 | ||
40 | 40 | let dappRunningKey = "conf_dapp_is_running" | |
41 | 41 | ||
42 | 42 | let maintenanceMSGKey = "conf_maintenance_msg" | |
43 | 43 | ||
44 | 44 | let dappRunning = valueOrElse(getBoolean(this, dappRunningKey), true) | |
45 | 45 | ||
46 | 46 | let maintenanceMSG = valueOrElse(getString(this, maintenanceMSGKey), "") | |
47 | 47 | ||
48 | 48 | let numSalesK = "num_sales" | |
49 | 49 | ||
50 | 50 | func getUserStrByK (key) = valueOrElse(getString(userDapp, key), "Error") | |
51 | 51 | ||
52 | 52 | ||
53 | 53 | func getArtStrByK (key) = valueOrElse(getString(artworksDapp, key), "") | |
54 | 54 | ||
55 | 55 | ||
56 | 56 | func getStrByK (key) = valueOrElse(getString(this, key), "") | |
57 | 57 | ||
58 | 58 | ||
59 | 59 | func getIntByK (key) = valueOrElse(getInteger(this, key), 0) | |
60 | 60 | ||
61 | 61 | ||
62 | 62 | func keyUserStatus (addr) = ("user_status_" + addr) | |
63 | 63 | ||
64 | 64 | ||
65 | 65 | func keySignID (artistAddr,artId) = ((("art_signid_" + artId) + "_") + artistAddr) | |
66 | 66 | ||
67 | 67 | ||
68 | 68 | func keyFlag (artistAddr,artId) = ((("art_flag_" + artId) + "_") + artistAddr) | |
69 | 69 | ||
70 | 70 | ||
71 | 71 | func keyNFTData (id) = ("nft_" + id) | |
72 | 72 | ||
73 | 73 | ||
74 | 74 | func getSaleKey (caller,nftId,artId,creatorAddr) = ((((((("sale2nd_info_" + caller) + "_") + nftId) + "_") + artId) + "_") + creatorAddr) | |
75 | 75 | ||
76 | 76 | ||
77 | 77 | func getBidKey (offerOwner,nftId,saleOwner,offerId) = ((((((("offer2nd_" + offerOwner) + "_") + nftId) + "_") + saleOwner) + "_") + offerId) | |
78 | 78 | ||
79 | 79 | ||
80 | 80 | func getIntByKFromOracle (key) = valueOrErrorMessage(getInteger(oracleFee, key), "Integer undefine or 0 in oracle") | |
81 | 81 | ||
82 | 82 | ||
83 | 83 | let currentCertificationPrice = getIntByKFromOracle(("certification_fee_" + toBase58String(signAssetId))) | |
84 | 84 | ||
85 | 85 | func idCallerDate (i) = if (!(dappRunning)) | |
86 | 86 | then throw(maintenanceMSG) | |
87 | 87 | else $Tuple3(toBase58String(i.transactionId), toBase58String(i.caller.bytes), lastBlock.timestamp) | |
88 | 88 | ||
89 | 89 | ||
90 | 90 | func isPayment (i) = if ((size(i.payments) == 0)) | |
91 | 91 | then throw("No payment attached") | |
92 | 92 | else { | |
93 | 93 | let payment = value(i.payments[0]) | |
94 | 94 | let amount = value(payment.amount) | |
95 | 95 | $Tuple2(payment, amount) | |
96 | 96 | } | |
97 | 97 | ||
98 | 98 | ||
99 | 99 | func assetIsValid (assetDetails) = if (if (if ((assetDetails.quantity == 1)) | |
100 | 100 | then (assetDetails.decimals == 0) | |
101 | 101 | else false) | |
102 | 102 | then (assetDetails.reissuable == false) | |
103 | 103 | else false) | |
104 | 104 | then (assetDetails.issuer == artworksDapp) | |
105 | 105 | else false | |
106 | 106 | ||
107 | 107 | ||
108 | 108 | func isSignArtNFT (id) = { | |
109 | 109 | let assetDetails = value(assetInfo(id)) | |
110 | 110 | assetIsValid(assetDetails) | |
111 | 111 | } | |
112 | 112 | ||
113 | 113 | ||
114 | 114 | func acceptedAssetIds (assetId) = if (if (if (if ((assetId != toBase58String(signAssetId))) | |
115 | 115 | then (assetId != toBase58String(wavesAssetId)) | |
116 | 116 | else false) | |
117 | 117 | then (assetId != "WAVES") | |
118 | 118 | else false) | |
119 | 119 | then (assetId != toBase58String(usdnAssetId)) | |
120 | 120 | else false) | |
121 | 121 | then false | |
122 | 122 | else true | |
123 | 123 | ||
124 | 124 | ||
125 | 125 | func getBidAssetId (assetId) = if ((assetId == "WAVES")) | |
126 | 126 | then unit | |
127 | 127 | else fromBase58String(assetId) | |
128 | 128 | ||
129 | 129 | ||
130 | 130 | func getSaleOwnerAndStatus (nftid) = { | |
131 | 131 | let saleOwner = getStrByK(("current_owner_on_dapp_" + nftid)) | |
132 | 132 | if ((size(saleOwner) == 0)) | |
133 | 133 | then throw("NFT not found") | |
134 | 134 | else { | |
135 | 135 | let saleStatus = getStrByK(((("sale2nd_status_" + saleOwner) + "_") + nftid)) | |
136 | 136 | if ((saleStatus != "OPEN")) | |
137 | 137 | then throw("NFT not for sale") | |
138 | 138 | else saleOwner | |
139 | 139 | } | |
140 | 140 | } | |
141 | 141 | ||
142 | 142 | ||
143 | 143 | func getBidData (key) = { | |
144 | 144 | let bidData = getStrByK((key + "_OPEN")) | |
145 | 145 | if ((bidData == "")) | |
146 | 146 | then throw("Offer not found") | |
147 | 147 | else { | |
148 | 148 | let bidDataArr = split(bidData, "_") | |
149 | 149 | let assetId = getBidAssetId(bidDataArr[2]) | |
150 | 150 | $Tuple3(bidDataArr, assetId, bidData) | |
151 | 151 | } | |
152 | 152 | } | |
153 | 153 | ||
154 | 154 | ||
155 | 155 | func artIsValid (artStatus) = if ((artStatus != artIllegal)) | |
156 | 156 | then (artStatus != artSuspended) | |
157 | 157 | else false | |
158 | 158 | ||
159 | 159 | ||
160 | 160 | func checkArtStatus (addr,id) = { | |
161 | 161 | let artStatus = getArtStrByK(keyFlag(addr, id)) | |
162 | 162 | if (artIsValid(artStatus)) | |
163 | 163 | then true | |
164 | 164 | else throw(("Original Artwork flagged as " + artStatus)) | |
165 | 165 | } | |
166 | 166 | ||
167 | 167 | ||
168 | 168 | func checkArtistStatus (addr) = { | |
169 | 169 | let artistStatus = getUserStrByK(keyUserStatus(addr)) | |
170 | 170 | if (containsElement([userSuspended, userRemoved], artistStatus)) | |
171 | 171 | then throw(("Original Artist " + artistStatus)) | |
172 | 172 | else true | |
173 | 173 | } | |
174 | 174 | ||
175 | 175 | ||
176 | 176 | func checkNFTInfo (assetId) = { | |
177 | 177 | let nftData = split(getArtStrByK(keyNFTData(assetId)), "_") | |
178 | 178 | let artSignID = getArtStrByK(keySignID(nftData[6], nftData[5])) | |
179 | 179 | if (if (!(checkArtStatus(nftData[6], nftData[5]))) | |
180 | 180 | then !(checkArtistStatus(nftData[6])) | |
181 | 181 | else false) | |
182 | 182 | then $Tuple4(false, nftData[5], nftData[6], artSignID) | |
183 | 183 | else $Tuple4(true, nftData[5], nftData[6], artSignID) | |
184 | 184 | } | |
185 | 185 | ||
186 | 186 | ||
187 | 187 | func checkARTExist (artId,creatorAddr) = { | |
188 | 188 | let artSignID = getArtStrByK(keySignID(creatorAddr, artId)) | |
189 | 189 | if ((size(artSignID) == 0)) | |
190 | 190 | then throw("Artwork not found on SIGN Art") | |
191 | 191 | else if (if (!(checkArtStatus(creatorAddr, artId))) | |
192 | 192 | then !(checkArtistStatus(creatorAddr)) | |
193 | 193 | else false) | |
194 | 194 | then false | |
195 | 195 | else true | |
196 | 196 | } | |
197 | 197 | ||
198 | 198 | ||
199 | 199 | func setTransfers (amount,assetId,nftid,creatorAddr,saleOwner,caller) = { | |
200 | 200 | let amountForSign = fraction(amount, signCut, 100) | |
201 | 201 | let amountForCreator = fraction(amount, creatorCut, 100) | |
202 | 202 | let amountForOwner = (amount - (amountForSign + amountForCreator)) | |
203 | 203 | let signFee = ScriptTransfer(Address(fromBase58String(feeReceiver)), amountForSign, assetId) | |
204 | 204 | let creatorFee = ScriptTransfer(Address(fromBase58String(creatorAddr)), amountForCreator, assetId) | |
205 | 205 | let ownerFee = ScriptTransfer(Address(fromBase58String(saleOwner)), amountForOwner, assetId) | |
206 | 206 | let collectorNFT = ScriptTransfer(Address(fromBase58String(caller)), 1, fromBase58String(nftid)) | |
207 | 207 | $Tuple4(signFee, creatorFee, ownerFee, collectorNFT) | |
208 | 208 | } | |
209 | 209 | ||
210 | 210 | ||
211 | 211 | func validateMinSell (assetId,price) = { | |
212 | 212 | let minSellWaves = if (unitTest) | |
213 | 213 | then 10 | |
214 | 214 | else getIntByKFromOracle("waves_min_sell") | |
215 | 215 | let minSellUsdn = 1000000 | |
216 | 216 | let minSellSign = if (unitTest) | |
217 | 217 | then 1 | |
218 | 218 | else (currentCertificationPrice * 2) | |
219 | 219 | if (if (if (if (if ((assetId == toBase58String(usdnAssetId))) | |
220 | 220 | then (minSellUsdn > price) | |
221 | 221 | else false) | |
222 | 222 | then (price != 0) | |
223 | 223 | else false) | |
224 | 224 | then true | |
225 | 225 | else if (if ((assetId == toBase58String(signAssetId))) | |
226 | 226 | then (minSellSign > price) | |
227 | 227 | else false) | |
228 | 228 | then (price != 0) | |
229 | 229 | else false) | |
230 | 230 | then true | |
231 | 231 | else if (if (if ((assetId == toBase58String(wavesAssetId))) | |
232 | 232 | then true | |
233 | 233 | else (assetId == "WAVES")) | |
234 | 234 | then (minSellWaves > price) | |
235 | 235 | else false) | |
236 | 236 | then (price != 0) | |
237 | 237 | else false) | |
238 | 238 | then false | |
239 | 239 | else true | |
240 | 240 | } | |
241 | 241 | ||
242 | 242 | ||
243 | 243 | func provideBaseData (i,nftId) = { | |
244 | - | let $ | |
245 | - | let id = $ | |
246 | - | let caller = $ | |
247 | - | let date = $ | |
248 | - | let $ | |
249 | - | let isValidNFT = $ | |
250 | - | let artId = $ | |
251 | - | let creatorAddr = $ | |
252 | - | let artSignID = $ | |
244 | + | let $t085778616 = idCallerDate(i) | |
245 | + | let id = $t085778616._1 | |
246 | + | let caller = $t085778616._2 | |
247 | + | let date = $t085778616._3 | |
248 | + | let $t086198688 = checkNFTInfo(nftId) | |
249 | + | let isValidNFT = $t086198688._1 | |
250 | + | let artId = $t086198688._2 | |
251 | + | let creatorAddr = $t086198688._3 | |
252 | + | let artSignID = $t086198688._4 | |
253 | 253 | $Tuple7(id, caller, date, isValidNFT, artId, creatorAddr, artSignID) | |
254 | 254 | } | |
255 | 255 | ||
256 | 256 | ||
257 | 257 | func updateNumSales () = { | |
258 | 258 | let numSales = getIntByK(numSalesK) | |
259 | 259 | IntegerEntry(numSalesK, (numSales + 1)) | |
260 | 260 | } | |
261 | 261 | ||
262 | 262 | ||
263 | 263 | @Callable(invoke) | |
264 | 264 | func appRunning (isLive,message) = { | |
265 | 265 | let caller = toString(addressFromPublicKey(invoke.callerPublicKey)) | |
266 | 266 | let id = toBase58String(invoke.transactionId) | |
267 | 267 | if (containsElement([chris, toString(this)], caller)) | |
268 | 268 | then [BooleanEntry(dappRunningKey, isLive), StringEntry(maintenanceMSGKey, message)] | |
269 | 269 | else throw("You are not allowed to change this") | |
270 | 270 | } | |
271 | 271 | ||
272 | 272 | ||
273 | 273 | ||
274 | 274 | @Callable(i) | |
275 | 275 | func sellNFT (price,asset) = { | |
276 | - | let $ | |
277 | - | let payment = $ | |
278 | - | let amount = $ | |
276 | + | let $t094019437 = isPayment(i) | |
277 | + | let payment = $t094019437._1 | |
278 | + | let amount = $t094019437._2 | |
279 | 279 | let nftId = if (if (isDefined(payment.assetId)) | |
280 | 280 | then isSignArtNFT(value(payment.assetId)) | |
281 | 281 | else false) | |
282 | 282 | then toBase58String(value(payment.assetId)) | |
283 | 283 | else throw("Only SIGN Art NFT accepted.") | |
284 | - | let $ | |
285 | - | let id = $ | |
286 | - | let caller = $ | |
287 | - | let date = $ | |
288 | - | let isValidNFT = $ | |
289 | - | let artId = $ | |
290 | - | let creatorAddr = $ | |
291 | - | let artSignID = $ | |
284 | + | let $t096169708 = provideBaseData(i, nftId) | |
285 | + | let id = $t096169708._1 | |
286 | + | let caller = $t096169708._2 | |
287 | + | let date = $t096169708._3 | |
288 | + | let isValidNFT = $t096169708._4 | |
289 | + | let artId = $t096169708._5 | |
290 | + | let creatorAddr = $t096169708._6 | |
291 | + | let artSignID = $t096169708._7 | |
292 | 292 | if ((size(artSignID) == 0)) | |
293 | 293 | then throw("Artwork not found on SIGN Art") | |
294 | 294 | else if (!(isValidNFT)) | |
295 | 295 | then throw("Not a valid nft") | |
296 | 296 | else if (!(acceptedAssetIds(asset))) | |
297 | 297 | then throw("Only SIGN, USDN or WAVES accepted") | |
298 | - | else if ((price | |
298 | + | else if (!(validateMinSell(asset, price))) | |
299 | 299 | then throw("Wrong minimum sell price") | |
300 | - | else if (!(validateMinSell(asset, price))) | |
301 | - | then throw("Wrong minimum sell price") | |
302 | - | else [StringEntry((getSaleKey(caller, nftId, artId, creatorAddr) + "_OPEN"), ((((((((((((toString(date) + "_") + toString(price)) + "_") + asset) + "_") + nftId) + "_") + artId) + "_") + creatorAddr) + "_") + id)), StringEntry(((("sale2nd_status_" + caller) + "_") + nftId), "OPEN"), StringEntry(("current_owner_on_dapp_" + nftId), caller)] | |
300 | + | else [StringEntry((getSaleKey(caller, nftId, artId, creatorAddr) + "_OPEN"), ((((((((((((toString(date) + "_") + toString(price)) + "_") + asset) + "_") + nftId) + "_") + artId) + "_") + creatorAddr) + "_") + id)), StringEntry(((("sale2nd_status_" + caller) + "_") + nftId), "OPEN"), StringEntry(("current_owner_on_dapp_" + nftId), caller)] | |
303 | 301 | } | |
304 | 302 | ||
305 | 303 | ||
306 | 304 | ||
307 | 305 | @Callable(i) | |
308 | 306 | func updateSalePrice (nftId,price,asset) = { | |
309 | - | let $ | |
310 | - | let id = $ | |
311 | - | let caller = $ | |
312 | - | let date = $ | |
313 | - | let isValidNFT = $ | |
314 | - | let artId = $ | |
315 | - | let creatorAddr = $ | |
316 | - | let artSignID = $ | |
307 | + | let $t01058210674 = provideBaseData(i, nftId) | |
308 | + | let id = $t01058210674._1 | |
309 | + | let caller = $t01058210674._2 | |
310 | + | let date = $t01058210674._3 | |
311 | + | let isValidNFT = $t01058210674._4 | |
312 | + | let artId = $t01058210674._5 | |
313 | + | let creatorAddr = $t01058210674._6 | |
314 | + | let artSignID = $t01058210674._7 | |
317 | 315 | if ((size(artSignID) == 0)) | |
318 | 316 | then throw("Artwork not found on SIGN Art, cancel your sale.") | |
319 | 317 | else if (!(isValidNFT)) | |
320 | 318 | then throw("Not a valid nft") | |
321 | 319 | else { | |
322 | 320 | let saleOwner = getStrByK(("current_owner_on_dapp_" + nftId)) | |
323 | 321 | if ((saleOwner != caller)) | |
324 | 322 | then throw("You don't own this NFT") | |
325 | 323 | else { | |
326 | 324 | let saleStatus = getStrByK(((("sale2nd_status_" + caller) + "_") + nftId)) | |
327 | 325 | if ((saleStatus != "OPEN")) | |
328 | 326 | then throw("Sale not active") | |
329 | 327 | else if (!(acceptedAssetIds(asset))) | |
330 | 328 | then throw("Only SIGN, USDN or WAVES accepted") | |
331 | 329 | else if ((price == 0)) | |
332 | 330 | then throw("Wrong minimum sell price") | |
333 | 331 | else if (!(validateMinSell(asset, price))) | |
334 | 332 | then throw("Wrong minimum sell price") | |
335 | 333 | else { | |
336 | 334 | let saleKey = getSaleKey(caller, nftId, artId, creatorAddr) | |
337 | 335 | let saleInfo = split(getStrByK((saleKey + "_OPEN")), "_") | |
338 | 336 | [StringEntry((saleKey + "_OPEN"), ((((((((((((saleInfo[0] + "_") + toString(price)) + "_") + asset) + "_") + saleInfo[3]) + "_") + saleInfo[4]) + "_") + saleInfo[5]) + "_") + saleInfo[6]))] | |
339 | 337 | } | |
340 | 338 | } | |
341 | 339 | } | |
342 | 340 | } | |
343 | 341 | ||
344 | 342 | ||
345 | 343 | ||
346 | 344 | @Callable(i) | |
347 | 345 | func cancelSale (nftId) = { | |
348 | - | let $ | |
349 | - | let id = $ | |
350 | - | let caller = $ | |
351 | - | let date = $ | |
352 | - | let isValidNFT = $ | |
353 | - | let artId = $ | |
354 | - | let creatorAddr = $ | |
355 | - | let artSignID = $ | |
346 | + | let $t01181412054 = provideBaseData(i, nftId) | |
347 | + | let id = $t01181412054._1 | |
348 | + | let caller = $t01181412054._2 | |
349 | + | let date = $t01181412054._3 | |
350 | + | let isValidNFT = $t01181412054._4 | |
351 | + | let artId = $t01181412054._5 | |
352 | + | let creatorAddr = $t01181412054._6 | |
353 | + | let artSignID = $t01181412054._7 | |
356 | 354 | let saleOwner = getStrByK(("current_owner_on_dapp_" + nftId)) | |
357 | 355 | if ((saleOwner != caller)) | |
358 | 356 | then throw("You don't own this NFT") | |
359 | 357 | else { | |
360 | 358 | let saleStatus = getStrByK(((("sale2nd_status_" + caller) + "_") + nftId)) | |
361 | 359 | if ((saleStatus != "OPEN")) | |
362 | 360 | then throw("Sale not active") | |
363 | 361 | else { | |
364 | 362 | let saleKey = getSaleKey(caller, nftId, artId, creatorAddr) | |
365 | 363 | let saleInfo = getStrByK((saleKey + "_OPEN")) | |
366 | 364 | [DeleteEntry((saleKey + "_OPEN")), DeleteEntry(((("sale2nd_status_" + caller) + "_") + nftId)), DeleteEntry(("current_owner_on_dapp_" + nftId)), StringEntry((((saleKey + "_") + id) + "_CANCELLED"), ((((saleInfo + "_CANCELLED_") + toString(date)) + "_") + id)), ScriptTransfer(Address(fromBase58String(caller)), 1, fromBase58String(nftId))] | |
367 | 365 | } | |
368 | 366 | } | |
369 | 367 | } | |
370 | 368 | ||
371 | 369 | ||
372 | 370 | ||
373 | 371 | @Callable(i) | |
374 | 372 | func buyNFT (nftId) = { | |
375 | - | let $ | |
376 | - | let id = $ | |
377 | - | let caller = $ | |
378 | - | let date = $ | |
379 | - | let isValidNFT = $ | |
380 | - | let artId = $ | |
381 | - | let creatorAddr = $ | |
382 | - | let artSignID = $ | |
373 | + | let $t01288512977 = provideBaseData(i, nftId) | |
374 | + | let id = $t01288512977._1 | |
375 | + | let caller = $t01288512977._2 | |
376 | + | let date = $t01288512977._3 | |
377 | + | let isValidNFT = $t01288512977._4 | |
378 | + | let artId = $t01288512977._5 | |
379 | + | let creatorAddr = $t01288512977._6 | |
380 | + | let artSignID = $t01288512977._7 | |
383 | 381 | if ((size(artSignID) == 0)) | |
384 | 382 | then throw("Artwork not found on SIGN Art, cancel your sale.") | |
385 | 383 | else if (!(isValidNFT)) | |
386 | 384 | then throw("Not a valid nft") | |
387 | 385 | else { | |
388 | 386 | let saleOwner = getSaleOwnerAndStatus(nftId) | |
389 | 387 | let saleKey = getSaleKey(saleOwner, nftId, artId, creatorAddr) | |
390 | 388 | let saleInfo = getStrByK((saleKey + "_OPEN")) | |
391 | 389 | if ((size(saleInfo) == 0)) | |
392 | 390 | then throw("Sale Not found!") | |
393 | 391 | else { | |
394 | 392 | let saleInfoArray = split(saleInfo, "_") | |
395 | 393 | if ((parseInt(saleInfoArray[1]) == 0)) | |
396 | 394 | then throw("Offer only") | |
397 | 395 | else { | |
398 | - | let $ | |
399 | - | let payment = $ | |
400 | - | let amount = $ | |
396 | + | let $t01347413510 = isPayment(i) | |
397 | + | let payment = $t01347413510._1 | |
398 | + | let amount = $t01347413510._2 | |
401 | 399 | let paymentAssetStr = if (isDefined(payment.assetId)) | |
402 | 400 | then toBase58String(value(payment.assetId)) | |
403 | 401 | else "" | |
404 | 402 | if (if ((saleInfoArray[1] != toString(amount))) | |
405 | 403 | then true | |
406 | 404 | else (saleInfoArray[2] != paymentAssetStr)) | |
407 | 405 | then throw("Payment infos don't match.") | |
408 | 406 | else { | |
409 | 407 | let amountForSign = fraction(amount, signCut, 100) | |
410 | 408 | let amountForCreator = fraction(amount, creatorCut, 100) | |
411 | 409 | let amountForOwner = (amount - (amountForSign + amountForCreator)) | |
412 | - | let $ | |
413 | - | let signFee = $ | |
414 | - | let creatorFee = $ | |
415 | - | let ownerFee = $ | |
416 | - | let collectorNFT = $ | |
410 | + | let $t01401314141 = setTransfers(amount, payment.assetId, nftId, creatorAddr, saleOwner, caller) | |
411 | + | let signFee = $t01401314141._1 | |
412 | + | let creatorFee = $t01401314141._2 | |
413 | + | let ownerFee = $t01401314141._3 | |
414 | + | let collectorNFT = $t01401314141._4 | |
417 | 415 | [DeleteEntry((saleKey + "_OPEN")), DeleteEntry(((("sale2nd_status_" + saleOwner) + "_") + nftId)), DeleteEntry(("current_owner_on_dapp_" + nftId)), StringEntry((((saleKey + "_") + id) + "_CLOSED"), ((((((saleInfo + "_CLOSED_") + toString(date)) + "_") + id) + "_") + caller)), updateNumSales(), signFee, creatorFee, ownerFee, collectorNFT] | |
418 | 416 | } | |
419 | 417 | } | |
420 | 418 | } | |
421 | 419 | } | |
422 | 420 | } | |
423 | 421 | ||
424 | 422 | ||
425 | 423 | ||
426 | 424 | @Callable(i) | |
427 | 425 | func setOffer (nftId) = { | |
428 | - | let $ | |
429 | - | let id = $ | |
430 | - | let offerOwner = $ | |
431 | - | let date = $ | |
432 | - | let isValidNFT = $ | |
433 | - | let artId = $ | |
434 | - | let creatorAddr = $ | |
435 | - | let artSignID = $ | |
426 | + | let $t01454914645 = provideBaseData(i, nftId) | |
427 | + | let id = $t01454914645._1 | |
428 | + | let offerOwner = $t01454914645._2 | |
429 | + | let date = $t01454914645._3 | |
430 | + | let isValidNFT = $t01454914645._4 | |
431 | + | let artId = $t01454914645._5 | |
432 | + | let creatorAddr = $t01454914645._6 | |
433 | + | let artSignID = $t01454914645._7 | |
436 | 434 | if (!(isValidNFT)) | |
437 | 435 | then throw("Not a valid nft") | |
438 | 436 | else { | |
439 | - | let $ | |
440 | - | let payment = $ | |
441 | - | let amount = $ | |
437 | + | let $t01470614742 = isPayment(i) | |
438 | + | let payment = $t01470614742._1 | |
439 | + | let amount = $t01470614742._2 | |
442 | 440 | let assetId = if (!(isDefined(payment.assetId))) | |
443 | 441 | then "WAVES" | |
444 | 442 | else toBase58String(value(payment.assetId)) | |
445 | 443 | if (!(acceptedAssetIds(assetId))) | |
446 | 444 | then throw("asset not accepted") | |
447 | 445 | else if ((amount == 0)) | |
448 | 446 | then throw("Offer of 0 not allowed") | |
449 | 447 | else if (!(validateMinSell(assetId, amount))) | |
450 | 448 | then throw("Wrong minimum sell price") | |
451 | 449 | else { | |
452 | 450 | let saleOwner = getSaleOwnerAndStatus(nftId) | |
453 | 451 | [StringEntry((getBidKey(offerOwner, nftId, saleOwner, id) + "_OPEN"), ((((((((((((((toString(date) + "_") + toString(amount)) + "_") + assetId) + "_") + nftId) + "_") + artId) + "_") + creatorAddr) + "_") + offerOwner) + "_") + id))] | |
454 | 452 | } | |
455 | 453 | } | |
456 | 454 | } | |
457 | 455 | ||
458 | 456 | ||
459 | 457 | ||
460 | 458 | @Callable(i) | |
461 | 459 | func acceptOffer (nftId,offerId,offerOwner) = { | |
462 | - | let $ | |
463 | - | let id = $ | |
464 | - | let caller = $ | |
465 | - | let date = $ | |
466 | - | let isValidNFT = $ | |
467 | - | let artId = $ | |
468 | - | let creatorAddr = $ | |
469 | - | let artSignID = $ | |
460 | + | let $t01554415636 = provideBaseData(i, nftId) | |
461 | + | let id = $t01554415636._1 | |
462 | + | let caller = $t01554415636._2 | |
463 | + | let date = $t01554415636._3 | |
464 | + | let isValidNFT = $t01554415636._4 | |
465 | + | let artId = $t01554415636._5 | |
466 | + | let creatorAddr = $t01554415636._6 | |
467 | + | let artSignID = $t01554415636._7 | |
470 | 468 | if (!(isValidNFT)) | |
471 | 469 | then throw("Not a valid nft") | |
472 | 470 | else { | |
473 | 471 | let saleOwner = getSaleOwnerAndStatus(nftId) | |
474 | 472 | if ((caller != saleOwner)) | |
475 | 473 | then throw("Only sale owner can accept offer") | |
476 | 474 | else { | |
477 | 475 | let bidKey = getBidKey(offerOwner, nftId, saleOwner, offerId) | |
478 | - | let $ | |
479 | - | let bidDataArr = $ | |
480 | - | let assetId = $ | |
481 | - | let bidData = $ | |
476 | + | let $t01589015945 = getBidData(bidKey) | |
477 | + | let bidDataArr = $t01589015945._1 | |
478 | + | let assetId = $t01589015945._2 | |
479 | + | let bidData = $t01589015945._3 | |
482 | 480 | let saleKey = getSaleKey(saleOwner, nftId, artId, creatorAddr) | |
483 | 481 | let saleInfo = getStrByK((saleKey + "_OPEN")) | |
484 | 482 | if ((size(saleInfo) == 0)) | |
485 | 483 | then throw("Sale Not found!") | |
486 | 484 | else { | |
487 | 485 | let amount = value(parseInt(bidDataArr[1])) | |
488 | - | let $ | |
489 | - | let signFee = $ | |
490 | - | let creatorFee = $ | |
491 | - | let ownerFee = $ | |
492 | - | let collectorNFT = $ | |
486 | + | let $t01617716304 = setTransfers(amount, assetId, nftId, creatorAddr, saleOwner, bidDataArr[6]) | |
487 | + | let signFee = $t01617716304._1 | |
488 | + | let creatorFee = $t01617716304._2 | |
489 | + | let ownerFee = $t01617716304._3 | |
490 | + | let collectorNFT = $t01617716304._4 | |
493 | 491 | [DeleteEntry((saleKey + "_OPEN")), DeleteEntry((bidKey + "_OPEN")), DeleteEntry(((("sale2nd_status_" + saleOwner) + "_") + nftId)), DeleteEntry(("current_owner_on_dapp_" + nftId)), StringEntry((bidKey + "_CLOSED"), ((((bidData + "_CLOSED_") + toString(date)) + "_") + id)), StringEntry((((saleKey + "_") + id) + "_CLOSED"), ((((((((((saleInfo + "_CLOSED-OFFER_") + toString(date)) + "_") + id) + "_") + offerOwner) + "_") + toString(amount)) + "_") + toBase58String(value(assetId)))), updateNumSales(), signFee, creatorFee, ownerFee, collectorNFT] | |
494 | 492 | } | |
495 | 493 | } | |
496 | 494 | } | |
497 | 495 | } | |
498 | 496 | ||
499 | 497 | ||
500 | 498 | ||
501 | 499 | @Callable(i) | |
502 | 500 | func cancelOffer (nftId,offerId,saleOwner) = { | |
503 | - | let $ | |
504 | - | let id = $ | |
505 | - | let caller = $ | |
506 | - | let date = $ | |
501 | + | let $t01700917070 = idCallerDate(i) | |
502 | + | let id = $t01700917070._1 | |
503 | + | let caller = $t01700917070._2 | |
504 | + | let date = $t01700917070._3 | |
507 | 505 | let bidKey = getBidKey(caller, nftId, saleOwner, offerId) | |
508 | - | let $ | |
509 | - | let bidDataArr = $ | |
510 | - | let assetId = $ | |
511 | - | let bidData = $ | |
506 | + | let $t01713417189 = getBidData(bidKey) | |
507 | + | let bidDataArr = $t01713417189._1 | |
508 | + | let assetId = $t01713417189._2 | |
509 | + | let bidData = $t01713417189._3 | |
512 | 510 | [DeleteEntry((bidKey + "_OPEN")), StringEntry((bidKey + "_CANCELLED"), ((((bidData + "_CANCELLED_") + toString(date)) + "_") + id)), ScriptTransfer(Address(fromBase58String(caller)), parseIntValue(bidDataArr[1]), assetId)] | |
513 | 511 | } | |
514 | 512 | ||
515 | 513 |
github/deemru/w8io/026f985 80.44 ms ◑