tx · 9kDGwgP1t1AmFViMTyAqXeptj59HjpgLnxizf5tn51tm 3NBynfbXC2KastUxhukcMUaE58K9cBdB9UY: -0.02500000 Waves 2023.01.20 08:50 [2412873] smart account 3NBynfbXC2KastUxhukcMUaE58K9cBdB9UY > SELF 0.00000000 Waves
{ "type": 13, "id": "9kDGwgP1t1AmFViMTyAqXeptj59HjpgLnxizf5tn51tm", "fee": 2500000, "feeAssetId": null, "timestamp": 1674193881642, "version": 2, "chainId": 84, "sender": "3NBynfbXC2KastUxhukcMUaE58K9cBdB9UY", "senderPublicKey": "J9DCtJJxJBWZdtDR12BA1U94Q3cZzMi4R6k5hYkAzmzC", "proofs": [ "274G5cp6UsWSBqPSbuP7p9P3VU5cUDnsBXeLoKmJ48bMWCF6bHvXLt8Kq9DoFAagGAP1NLNSZzx3u7JsyFHpaQPt" ], "script": "base64:BgJfCAISBAoCCAgSEAoOCAgICAgICAgICAgIAQgSDwoNCAgICAgICAgICAgBCBIGCgQICAgIEgQKAggIEggKBggBAQgBCBIECgIICBIECgIICBIGCgQICAgIEgYKBAgICAhOAAdWRVJTSU9OAgYxLjEuMTABDmdldFN0cmluZ0J5S2V5AQNrZXkJAQt2YWx1ZU9yRWxzZQIJAJ0IAgUEdGhpcwUDa2V5AgAACHVuaXRUZXN0BwAJb3JhY2xlRmVlCQEFdmFsdWUBCQCmCAEJAQ5nZXRTdHJpbmdCeUtleQECD2NvbmZfb3JhY2xlX2ZlZQAIc2lnbkRhcHAJAQV2YWx1ZQEJAKYIAQkBDmdldFN0cmluZ0J5S2V5AQIRY29uZl9zaWdud2ViX2RhcHAAC2ZlZVJlY2VpdmVyCQEOZ2V0U3RyaW5nQnlLZXkBAhFjb25mX2ZlZV9yZWNlaXZlcgAIdXNlckRhcHADBQh1bml0VGVzdAkBBXZhbHVlAQkApggBAiMzTXQ0UkdNRXlqU1dZQW9jVFBxZDU1d2RIUVFCM1BVMlVDbQkBBXZhbHVlAQkApggBCQEOZ2V0U3RyaW5nQnlL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w==", "height": 2412873, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 93JCaHiMe8d3iUnAkzqD2ThmDqzwA16MmdTgZY851yti Next: 3ZUTcCayZHYn1JFS9VeNdFqmzVTNykM65drrUGxsapRa Diff:
Old | New | Differences | |
---|---|---|---|
376 | 376 | func idCallerDateSponsored (i,pubKey) = if (!(dappRunning)) | |
377 | 377 | then throw(maintenanceMSG) | |
378 | 378 | else { | |
379 | - | let isSponsored = valueOrElse(checkWhitelist((toString(addressFromPublicKey(fromBase58String(pubKey))) + "_free_txs")), 0) | |
379 | + | let isSponsored = if ((pubKey != "")) | |
380 | + | then valueOrElse(checkWhitelist((toString(addressFromPublicKey(fromBase58String(pubKey))) + "_free_txs")), 0) | |
381 | + | else 0 | |
380 | 382 | let caller = if (if (if ((toBase58String(i.caller.bytes) == toString(this))) | |
381 | 383 | then (size(i.payments) == 0) | |
382 | 384 | else false) | |
399 | 401 | ||
400 | 402 | ||
401 | 403 | func buyMint (i,artId,issuer,bidId,bidOwner) = { | |
402 | - | let $ | |
403 | - | let id = $ | |
404 | - | let caller = $ | |
405 | - | let date = $ | |
404 | + | let $t01294713006 = idCallerDate(i) | |
405 | + | let id = $t01294713006._1 | |
406 | + | let caller = $t01294713006._2 | |
407 | + | let date = $t01294713006._3 | |
406 | 408 | let isBid = if (if (if ((caller == issuer)) | |
407 | 409 | then (bidOwner != "") | |
408 | 410 | else false) | |
458 | 460 | then throw(checkUser) | |
459 | 461 | else { | |
460 | 462 | let bidDataKey = ((((((("bid_" + artId) + "_") + issuer) + "_") + bidOwner) + "_") + bidId) | |
461 | - | let $ | |
463 | + | let $t01470914876 = if (isBid) | |
462 | 464 | then getPriceAssetIdFromBid(bidDataKey) | |
463 | 465 | else validatePriceAssetId(i, priceAssetId, artworkPrice) | |
464 | - | let amount = $ | |
465 | - | let assetId = $ | |
466 | + | let amount = $t01470914876._1 | |
467 | + | let assetId = $t01470914876._2 | |
466 | 468 | let agent = valueOrElse(getString(userDapp, keyArtistAgentAddr(issuer)), feeReceiver) | |
467 | 469 | let agentShare = valueOrElse(getInteger(userDapp, keyPrimaryShare(issuer)), 0) | |
468 | 470 | let isWhitelisted = checkWhitelist(issuer) | |
551 | 553 | ||
552 | 554 | @Callable(i) | |
553 | 555 | func addArtwork (sha256Hash,signID,name,description,tags,type,cidDisplay,sha256Export,cidExport,sha256Licence,cidLicence,crawler,royalties,pubKey) = { | |
554 | - | let $ | |
555 | - | let artId = $ | |
556 | - | let caller = $ | |
557 | - | let date = $ | |
558 | - | let isSponsored = $ | |
556 | + | let $t01890918982 = idCallerDateSponsored(i, pubKey) | |
557 | + | let artId = $t01890918982._1 | |
558 | + | let caller = $t01890918982._2 | |
559 | + | let date = $t01890918982._3 | |
560 | + | let isSponsored = $t01890918982._4 | |
559 | 561 | if (!(validateHash(sha256Hash))) | |
560 | 562 | then throw("Hash should be 64 characters maximum") | |
561 | 563 | else { | |
562 | - | let $ | |
563 | - | let licenceCID = $ | |
564 | - | let licenceHash = $ | |
564 | + | let $t01908319152 = setLIcence(cidLicence, sha256Licence) | |
565 | + | let licenceCID = $t01908319152._1 | |
566 | + | let licenceHash = $t01908319152._2 | |
565 | 567 | let validateArtwork = validateArtworkData(caller, cidDisplay, cidExport, licenceCID, sha256Export, licenceHash, name, description, tags, royalties) | |
566 | 568 | if ((validateArtwork != "")) | |
567 | 569 | then throw("Something went wrong!") | |
568 | 570 | else { | |
569 | 571 | let whitelisted_drop = (checkWhitelist((caller + "_free_drops")) > 0) | |
570 | - | let $ | |
572 | + | let $t01945119535 = if (whitelisted_drop) | |
571 | 573 | then $Tuple2(0, signID) | |
572 | 574 | else validatePayment(i) | |
573 | - | let amount = $ | |
574 | - | let assetId = $ | |
575 | + | let amount = $t01945119535._1 | |
576 | + | let assetId = $t01945119535._2 | |
575 | 577 | if (!(isDefined(amount))) | |
576 | 578 | then throw("Something went wrong") | |
577 | 579 | else { | |
612 | 614 | func updateArtwork (txid,name,description,tags,type,cidDisplay,sha256Export,cidExport,sha256Licence,cidLicence,crawler,royalties,pubKey) = if (!(dappRunning)) | |
613 | 615 | then throw(maintenanceMSG) | |
614 | 616 | else { | |
615 | - | let $ | |
616 | - | let id = $ | |
617 | - | let caller = $ | |
618 | - | let date = $ | |
619 | - | let isSponsored = $ | |
620 | - | let $ | |
621 | - | let licenceCID = $ | |
622 | - | let licenceHash = $ | |
617 | + | let $t02256922639 = idCallerDateSponsored(i, pubKey) | |
618 | + | let id = $t02256922639._1 | |
619 | + | let caller = $t02256922639._2 | |
620 | + | let date = $t02256922639._3 | |
621 | + | let isSponsored = $t02256922639._4 | |
622 | + | let $t02264922718 = setLIcence(cidLicence, sha256Licence) | |
623 | + | let licenceCID = $t02264922718._1 | |
624 | + | let licenceHash = $t02264922718._2 | |
623 | 625 | let validateArtwork = validateArtworkData(caller, cidDisplay, cidExport, licenceCID, sha256Export, licenceHash, name, description, tags, royalties) | |
624 | 626 | if ((validateArtwork != "")) | |
625 | 627 | then throw("Something went wrong!") | |
647 | 649 | ||
648 | 650 | @Callable(i) | |
649 | 651 | func flagArtwork (artId,addr,flag,note) = { | |
650 | - | let $ | |
651 | - | let id = $ | |
652 | - | let caller = $ | |
652 | + | let $t02434524379 = idCallerDate(i) | |
653 | + | let id = $t02434524379._1 | |
654 | + | let caller = $t02434524379._2 | |
653 | 655 | if (containsElement([chris, toString(this)], caller)) | |
654 | 656 | then if (containsElement(["CONSENT", "", "CHANGE_REQUIRED", "FLAGGED", "ILLEGAL"], flag)) | |
655 | 657 | then [StringEntry(keyFlag(addr, artId), flag), StringEntry(keyNote(addr, artId), note)] | |
661 | 663 | ||
662 | 664 | @Callable(i) | |
663 | 665 | func deleteArtwork (artId,addr) = { | |
664 | - | let $ | |
665 | - | let id = $ | |
666 | - | let caller = $ | |
666 | + | let $t02481524849 = idCallerDate(i) | |
667 | + | let id = $t02481524849._1 | |
668 | + | let caller = $t02481524849._2 | |
667 | 669 | let addrToUse = if (containsElement([chris, toString(this)], caller)) | |
668 | 670 | then addr | |
669 | 671 | else caller | |
696 | 698 | ||
697 | 699 | @Callable(i) | |
698 | 700 | func sellArtwork (artId,price,maxMint,assetId,blockEnd,pubKey) = { | |
699 | - | let $ | |
700 | - | let id = $ | |
701 | - | let caller = $ | |
702 | - | let date = $ | |
703 | - | let isSponsored = $ | |
701 | + | let $t02768527755 = idCallerDateSponsored(i, pubKey) | |
702 | + | let id = $t02768527755._1 | |
703 | + | let caller = $t02768527755._2 | |
704 | + | let date = $t02768527755._3 | |
705 | + | let isSponsored = $t02768527755._4 | |
704 | 706 | let artworkName = getStringByKey(keyName(caller, artId)) | |
705 | 707 | if ((artworkName == "")) | |
706 | 708 | then throw("This art doesn't match your account") | |
774 | 776 | ||
775 | 777 | @Callable(i) | |
776 | 778 | func setBid (artId,issuer) = { | |
777 | - | let $ | |
778 | - | let id = $ | |
779 | - | let caller = $ | |
780 | - | let date = $ | |
781 | - | let $ | |
782 | - | let payment = $ | |
783 | - | let amount = $ | |
779 | + | let $t03013330173 = idCallerDate(i) | |
780 | + | let id = $t03013330173._1 | |
781 | + | let caller = $t03013330173._2 | |
782 | + | let date = $t03013330173._3 | |
783 | + | let $t03017830214 = isPayment(i) | |
784 | + | let payment = $t03017830214._1 | |
785 | + | let amount = $t03017830214._2 | |
784 | 786 | let assetId = if (!(isDefined(payment.assetId))) | |
785 | 787 | then "WAVES" | |
786 | 788 | else toBase58String(value(payment.assetId)) | |
811 | 813 | ||
812 | 814 | @Callable(i) | |
813 | 815 | func acceptBid (artId,issuer,bidId,bidOwner) = { | |
814 | - | let $ | |
815 | - | let id = $ | |
816 | - | let caller = $ | |
817 | - | let date = $ | |
816 | + | let $t03137231412 = idCallerDate(i) | |
817 | + | let id = $t03137231412._1 | |
818 | + | let caller = $t03137231412._2 | |
819 | + | let date = $t03137231412._3 | |
818 | 820 | if ((caller != issuer)) | |
819 | 821 | then throw("You cannot do this action") | |
820 | 822 | else buyMint(i, artId, issuer, bidId, bidOwner) | |
824 | 826 | ||
825 | 827 | @Callable(i) | |
826 | 828 | func cancelBid (artId,issuer,bidId,bidOwner) = { | |
827 | - | let $ | |
828 | - | let id = $ | |
829 | - | let caller = $ | |
830 | - | let date = $ | |
829 | + | let $t03163831699 = idCallerDate(i) | |
830 | + | let id = $t03163831699._1 | |
831 | + | let caller = $t03163831699._2 | |
832 | + | let date = $t03163831699._3 | |
831 | 833 | if (if ((caller != bidOwner)) | |
832 | 834 | then (caller != issuer) | |
833 | 835 | else false) |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let VERSION = "1.1.10" | |
5 | 5 | ||
6 | 6 | func getStringByKey (key) = valueOrElse(getString(this, key), "") | |
7 | 7 | ||
8 | 8 | ||
9 | 9 | let unitTest = false | |
10 | 10 | ||
11 | 11 | let oracleFee = value(addressFromString(getStringByKey("conf_oracle_fee"))) | |
12 | 12 | ||
13 | 13 | let signDapp = value(addressFromString(getStringByKey("conf_signweb_dapp"))) | |
14 | 14 | ||
15 | 15 | let feeReceiver = getStringByKey("conf_fee_receiver") | |
16 | 16 | ||
17 | 17 | let userDapp = if (unitTest) | |
18 | 18 | then value(addressFromString("3Mt4RGMEyjSWYAocTPqd55wdHQQB3PU2UCm")) | |
19 | 19 | else value(addressFromString(getStringByKey("conf_users_dapp"))) | |
20 | 20 | ||
21 | 21 | let whitelistDapp = value(addressFromString(getStringByKey("conf_whitelist_dapp"))) | |
22 | 22 | ||
23 | 23 | let signAssetId = fromBase58String(getStringByKey("conf_accepted_asset_SIGN")) | |
24 | 24 | ||
25 | 25 | let usdnAssetId = fromBase58String(getStringByKey("conf_accepted_asset_USDN")) | |
26 | 26 | ||
27 | 27 | let usdtAssetId = fromBase58String(getStringByKey("conf_accepted_asset_USDT")) | |
28 | 28 | ||
29 | 29 | let wavesAssetId = base58'' | |
30 | 30 | ||
31 | 31 | let chris = getStringByKey("conf_admin_1") | |
32 | 32 | ||
33 | 33 | func getIntegerByKeyFromOracle (key) = valueOrErrorMessage(getInteger(oracleFee, key), "Integer undefine or 0 in oracle") | |
34 | 34 | ||
35 | 35 | ||
36 | 36 | func getIntegerByKey (key) = valueOrElse(getInteger(this, key), 0) | |
37 | 37 | ||
38 | 38 | ||
39 | 39 | func checkWhitelist (key) = valueOrElse(getInteger(whitelistDapp, key), 0) | |
40 | 40 | ||
41 | 41 | ||
42 | 42 | func getBooleanByKey (key) = valueOrElse(getBoolean(this, key), false) | |
43 | 43 | ||
44 | 44 | ||
45 | 45 | let signCut = 7 | |
46 | 46 | ||
47 | 47 | let usdnWaveCut = 10 | |
48 | 48 | ||
49 | 49 | let defaultLicence = getStringByKey("conf_default_licence") | |
50 | 50 | ||
51 | 51 | let defaultHashLicence = getStringByKey("conf_default_licence_hash") | |
52 | 52 | ||
53 | 53 | let dappRunning = valueOrElse(getBoolean(userDapp, "conf_dapp_is_running"), true) | |
54 | 54 | ||
55 | 55 | let maintenanceMSG = valueOrElse(getString(userDapp, "conf_maintenance_msg"), "") | |
56 | 56 | ||
57 | 57 | let userSuspended = "SUSPENDED" | |
58 | 58 | ||
59 | 59 | let userRemoved = "REMOVED" | |
60 | 60 | ||
61 | 61 | let userUnregistered = "UNREGISTERED" | |
62 | 62 | ||
63 | 63 | let userAllowed = "ALLOWED" | |
64 | 64 | ||
65 | 65 | let currentCertificationPrice = getIntegerByKeyFromOracle(("certification_fee_" + toBase58String(signAssetId))) | |
66 | 66 | ||
67 | 67 | func getArtworkRoyalties (key) = valueOrElse(getInteger(this, key), 1000) | |
68 | 68 | ||
69 | 69 | ||
70 | 70 | func checkSignCertificate (signID,Owner,sha256Hash) = match getString(signDapp, ((("data_fc_" + signID) + "_") + Owner)) { | |
71 | 71 | case a: String => | |
72 | 72 | if (contains(a, sha256Hash)) | |
73 | 73 | then true | |
74 | 74 | else false | |
75 | 75 | case _ => | |
76 | 76 | false | |
77 | 77 | } | |
78 | 78 | ||
79 | 79 | ||
80 | 80 | func validateCID (cid) = if (contains(cid, "/")) | |
81 | 81 | then if (if ((76 > size(cid))) | |
82 | 82 | then (size(split(cid, "/")[0]) == 59) | |
83 | 83 | else false) | |
84 | 84 | then (16 > size(split(cid, "/")[1])) | |
85 | 85 | else false | |
86 | 86 | else false | |
87 | 87 | ||
88 | 88 | ||
89 | 89 | func validateHash (hash) = (size(hash) == 64) | |
90 | 90 | ||
91 | 91 | ||
92 | 92 | func keyUserStatus (caller) = ("user_status_" + caller) | |
93 | 93 | ||
94 | 94 | ||
95 | 95 | func keyDate (caller,artId) = ((("art_date_" + artId) + "_") + caller) | |
96 | 96 | ||
97 | 97 | ||
98 | 98 | func keyName (caller,artId) = ((("art_name_" + artId) + "_") + caller) | |
99 | 99 | ||
100 | 100 | ||
101 | 101 | func keyDesc (caller,artId) = ((("art_desc_" + artId) + "_") + caller) | |
102 | 102 | ||
103 | 103 | ||
104 | 104 | func keyDisplayCid (caller,artId) = ((("art_display_cid_" + artId) + "_") + caller) | |
105 | 105 | ||
106 | 106 | ||
107 | 107 | func keyExportHash (caller,artId) = ((("art_export_hash_" + artId) + "_") + caller) | |
108 | 108 | ||
109 | 109 | ||
110 | 110 | func keyExportCid (caller,artId) = ((("art_export_cid_" + artId) + "_") + caller) | |
111 | 111 | ||
112 | 112 | ||
113 | 113 | func keyMaxMint (caller,artId) = ((("art_maxmint_" + artId) + "_") + caller) | |
114 | 114 | ||
115 | 115 | ||
116 | 116 | func keySignID (caller,artId) = ((("art_signid_" + artId) + "_") + caller) | |
117 | 117 | ||
118 | 118 | ||
119 | 119 | func keyIssued (caller,artId) = ((("art_issued_" + artId) + "_") + caller) | |
120 | 120 | ||
121 | 121 | ||
122 | 122 | func keyOnSale (caller,artId) = ((("art_onsale_" + artId) + "_") + caller) | |
123 | 123 | ||
124 | 124 | ||
125 | 125 | func keyLicenceHash (caller,artId) = ((("art_licence_hash_" + artId) + "_") + caller) | |
126 | 126 | ||
127 | 127 | ||
128 | 128 | func keyLicenceCid (caller,artId) = ((("art_licence_cid_" + artId) + "_") + caller) | |
129 | 129 | ||
130 | 130 | ||
131 | 131 | func keyTags (caller,artId) = ((("art_tags_" + artId) + "_") + caller) | |
132 | 132 | ||
133 | 133 | ||
134 | 134 | func keyType (caller,artId) = ((("art_type_" + artId) + "_") + caller) | |
135 | 135 | ||
136 | 136 | ||
137 | 137 | func keyNote (caller,artId) = ((("art_note_" + artId) + "_") + caller) | |
138 | 138 | ||
139 | 139 | ||
140 | 140 | func keyCrawler (caller,artId) = ((("art_crawler_cid_" + artId) + "_") + caller) | |
141 | 141 | ||
142 | 142 | ||
143 | 143 | func keyRoyalties (caller,artId) = ((("art_royalties_" + artId) + "_") + caller) | |
144 | 144 | ||
145 | 145 | ||
146 | 146 | func keyPrice (caller,artId) = ((("art_price_" + artId) + "_") + caller) | |
147 | 147 | ||
148 | 148 | ||
149 | 149 | func keyEndSale (caller,artId) = ((("art_endsale_" + artId) + "_") + caller) | |
150 | 150 | ||
151 | 151 | ||
152 | 152 | func keyAssetIdAccepted (caller,artId) = ((("art_assetAccepted_" + artId) + "_") + caller) | |
153 | 153 | ||
154 | 154 | ||
155 | 155 | func keyFlag (caller,artId) = ((("art_flag_" + artId) + "_") + caller) | |
156 | 156 | ||
157 | 157 | ||
158 | 158 | func keyArtistAgentAddr (artistAddr) = ("artist_agent_" + artistAddr) | |
159 | 159 | ||
160 | 160 | ||
161 | 161 | func keyPrimaryShare (artistAddr) = ("artist_agent_primary_" + artistAddr) | |
162 | 162 | ||
163 | 163 | ||
164 | 164 | func keyHashByTxidAddr (caller,txid) = ((("get_hashbytxidaddr_" + txid) + "_") + caller) | |
165 | 165 | ||
166 | 166 | ||
167 | 167 | func keyOwnerByHash (sha256Hash) = ("get_owner_by_hash_" + sha256Hash) | |
168 | 168 | ||
169 | 169 | ||
170 | 170 | func keyidBySignid (caller,signId) = ((("get_artidbysignid_" + signId) + "_") + caller) | |
171 | 171 | ||
172 | 172 | ||
173 | 173 | func keyTxidByHashOwner (sha256Hash,caller) = ("get_txid_by_hash_owner_" + toBase58String(sha256_16Kb(toBytes((sha256Hash + caller))))) | |
174 | 174 | ||
175 | 175 | ||
176 | 176 | func validateAllCID (cidDisplay,cidExport,cidLicence) = if (!(validateCID(cidDisplay))) | |
177 | 177 | then throw("Wrong Display CID") | |
178 | 178 | else if (!(validateCID(cidExport))) | |
179 | 179 | then throw("Wrong Export CID") | |
180 | 180 | else if (if ((cidLicence != "")) | |
181 | 181 | then !(validateCID(cidLicence)) | |
182 | 182 | else false) | |
183 | 183 | then throw("Wrong Licence CID") | |
184 | 184 | else true | |
185 | 185 | ||
186 | 186 | ||
187 | 187 | func validateAllHash (sha256Export,sha256Licence) = if (!(validateHash(sha256Export))) | |
188 | 188 | then throw("Export Hash 64 char. max") | |
189 | 189 | else if (!(validateHash(sha256Licence))) | |
190 | 190 | then throw("Licence Hash 64 char. max") | |
191 | 191 | else true | |
192 | 192 | ||
193 | 193 | ||
194 | 194 | func validateString (str,max) = if ((size(str) == 0)) | |
195 | 195 | then throw("Field cannot be is empty") | |
196 | 196 | else if ((size(str) > max)) | |
197 | 197 | then throw((str + " is too long")) | |
198 | 198 | else true | |
199 | 199 | ||
200 | 200 | ||
201 | 201 | func validateUser (caller) = { | |
202 | 202 | let userStatus = valueOrElse(getString(userDapp, keyUserStatus(caller)), userUnregistered) | |
203 | 203 | if (if ((userStatus == userUnregistered)) | |
204 | 204 | then true | |
205 | 205 | else (userStatus == userAllowed)) | |
206 | 206 | then "Register this account first with \"Account\" tab" | |
207 | 207 | else if ((userStatus == userSuspended)) | |
208 | 208 | then "Account suspended" | |
209 | 209 | else if ((userStatus == userRemoved)) | |
210 | 210 | then "Account removed" | |
211 | 211 | else "" | |
212 | 212 | } | |
213 | 213 | ||
214 | 214 | ||
215 | 215 | func setLIcence (cidLicence,sha256Licence) = { | |
216 | 216 | let cid = if ((size(cidLicence) == 0)) | |
217 | 217 | then defaultLicence | |
218 | 218 | else cidLicence | |
219 | 219 | let hash = if ((size(sha256Licence) == 0)) | |
220 | 220 | then defaultHashLicence | |
221 | 221 | else sha256Licence | |
222 | 222 | $Tuple2(cid, hash) | |
223 | 223 | } | |
224 | 224 | ||
225 | 225 | ||
226 | 226 | func validateArtworkData (caller,cidDisplay,cidExport,licenceCID,sha256Export,licenceHash,name,description,tags,royalties) = { | |
227 | 227 | let checkUser = validateUser(caller) | |
228 | 228 | if ((checkUser != "")) | |
229 | 229 | then throw(checkUser) | |
230 | 230 | else if ((size(cidDisplay) == 0)) | |
231 | 231 | then throw("Display CID cannot be empty") | |
232 | 232 | else if (!(validateAllCID(cidDisplay, cidExport, licenceCID))) | |
233 | 233 | then throw("Problem with CID") | |
234 | 234 | else if (!(validateAllHash(sha256Export, licenceHash))) | |
235 | 235 | then throw("Problem with Hashes") | |
236 | 236 | else if (!(validateString(name, 100))) | |
237 | 237 | then throw("100 Char. max name") | |
238 | 238 | else if (!(validateString(description, 1000))) | |
239 | 239 | then throw("1000 Char. max description") | |
240 | 240 | else if (if ((0 > royalties)) | |
241 | 241 | then true | |
242 | 242 | else (royalties > 1000)) | |
243 | 243 | then throw("Royalties cannot be less than 0% or higher than 10%") | |
244 | 244 | else if ((size(split(tags, ",")) > 5)) | |
245 | 245 | then throw("5 tags max.") | |
246 | 246 | else "" | |
247 | 247 | } | |
248 | 248 | ||
249 | 249 | ||
250 | 250 | func isPayment (i) = if ((size(i.payments) == 0)) | |
251 | 251 | then throw("No payment attached") | |
252 | 252 | else { | |
253 | 253 | let payment = value(i.payments[0]) | |
254 | 254 | let amount = value(payment.amount) | |
255 | 255 | $Tuple2(payment, amount) | |
256 | 256 | } | |
257 | 257 | ||
258 | 258 | ||
259 | 259 | func validatePayment (i) = { | |
260 | 260 | let $t089078943 = isPayment(i) | |
261 | 261 | let payment = $t089078943._1 | |
262 | 262 | let amount = $t089078943._2 | |
263 | 263 | let assetId = if (if (isDefined(payment.assetId)) | |
264 | 264 | then (payment.assetId == signAssetId) | |
265 | 265 | else false) | |
266 | 266 | then payment.assetId | |
267 | 267 | else throw("Only SIGN token accepted as transaction fee") | |
268 | 268 | if ((amount != currentCertificationPrice)) | |
269 | 269 | then throw(("Payment amount should be " + toString(currentCertificationPrice))) | |
270 | 270 | else $Tuple2(amount, assetId) | |
271 | 271 | } | |
272 | 272 | ||
273 | 273 | ||
274 | 274 | func isArtMinted (addrToUse,artId) = match getInteger(this, keyIssued(addrToUse, artId)) { | |
275 | 275 | case b: Int => | |
276 | 276 | if ((b != 0)) | |
277 | 277 | then true | |
278 | 278 | else false | |
279 | 279 | case _ => | |
280 | 280 | false | |
281 | 281 | } | |
282 | 282 | ||
283 | 283 | ||
284 | 284 | func validatePriceAssetId (i,priceAssetId,artworkPrice) = { | |
285 | 285 | let $t095319567 = isPayment(i) | |
286 | 286 | let payment = $t095319567._1 | |
287 | 287 | let amount = $t095319567._2 | |
288 | 288 | let assetId = if (!(isDefined(payment.assetId))) | |
289 | 289 | then unit | |
290 | 290 | else if (if ((size(priceAssetId) > 0)) | |
291 | 291 | then (toBase58String(value(payment.assetId)) == priceAssetId) | |
292 | 292 | else false) | |
293 | 293 | then payment.assetId | |
294 | 294 | else throw("Wrong asset id") | |
295 | 295 | if (if ((assetId == unit)) | |
296 | 296 | then (priceAssetId != "") | |
297 | 297 | else false) | |
298 | 298 | then throw("Wrong asset id") | |
299 | 299 | else if ((artworkPrice != amount)) | |
300 | 300 | then throw("Payment don't match") | |
301 | 301 | else $Tuple2(amount, assetId) | |
302 | 302 | } | |
303 | 303 | ||
304 | 304 | ||
305 | 305 | func acceptedAssetIds (assetId) = if (if (if (if (if ((assetId != toBase58String(signAssetId))) | |
306 | 306 | then (assetId != toBase58String(wavesAssetId)) | |
307 | 307 | else false) | |
308 | 308 | then (assetId != "WAVES") | |
309 | 309 | else false) | |
310 | 310 | then (assetId != toBase58String(usdnAssetId)) | |
311 | 311 | else false) | |
312 | 312 | then (assetId != toBase58String(usdtAssetId)) | |
313 | 313 | else false) | |
314 | 314 | then throw("Only SIGN, USDN,USDT or WAVES accepted") | |
315 | 315 | else true | |
316 | 316 | ||
317 | 317 | ||
318 | 318 | func validateMinSell (assetId,price) = { | |
319 | 319 | let minSellWaves = if (unitTest) | |
320 | 320 | then 10 | |
321 | 321 | else getIntegerByKeyFromOracle("waves_min_sell") | |
322 | 322 | let minSellUsdn = 1000000 | |
323 | 323 | let minSellSign = if (unitTest) | |
324 | 324 | then 1 | |
325 | 325 | else (currentCertificationPrice * 2) | |
326 | 326 | if (if (if (if (if (if ((assetId == toBase58String(usdnAssetId))) | |
327 | 327 | then (minSellUsdn > price) | |
328 | 328 | else false) | |
329 | 329 | then (price != 0) | |
330 | 330 | else false) | |
331 | 331 | then true | |
332 | 332 | else if (if ((assetId == toBase58String(usdtAssetId))) | |
333 | 333 | then (minSellUsdn > price) | |
334 | 334 | else false) | |
335 | 335 | then (price != 0) | |
336 | 336 | else false) | |
337 | 337 | then true | |
338 | 338 | else if (if ((assetId == toBase58String(signAssetId))) | |
339 | 339 | then (minSellSign > price) | |
340 | 340 | else false) | |
341 | 341 | then (price != 0) | |
342 | 342 | else false) | |
343 | 343 | then true | |
344 | 344 | else if (if (if ((assetId == toBase58String(wavesAssetId))) | |
345 | 345 | then true | |
346 | 346 | else (assetId == "WAVES")) | |
347 | 347 | then (minSellWaves > price) | |
348 | 348 | else false) | |
349 | 349 | then (price != 0) | |
350 | 350 | else false) | |
351 | 351 | then throw("Wrong minimum sell price") | |
352 | 352 | else true | |
353 | 353 | } | |
354 | 354 | ||
355 | 355 | ||
356 | 356 | func getBidAssetId (assetId) = if ((assetId == "WAVES")) | |
357 | 357 | then unit | |
358 | 358 | else fromBase58String(assetId) | |
359 | 359 | ||
360 | 360 | ||
361 | 361 | func getPriceAssetIdFromBid (bidDataKey) = { | |
362 | 362 | let bidData = getStringByKey((bidDataKey + "_OPEN")) | |
363 | 363 | if ((bidData == "")) | |
364 | 364 | then throw("Bid not found") | |
365 | 365 | else { | |
366 | 366 | let bidDataArr = split(bidData, "_") | |
367 | 367 | let bidAmount = parseIntValue(bidDataArr[1]) | |
368 | 368 | let bidAssetId = getBidAssetId(bidDataArr[0]) | |
369 | 369 | if ((0 >= bidAmount)) | |
370 | 370 | then throw("Wrong amount") | |
371 | 371 | else $Tuple2(bidAmount, bidAssetId) | |
372 | 372 | } | |
373 | 373 | } | |
374 | 374 | ||
375 | 375 | ||
376 | 376 | func idCallerDateSponsored (i,pubKey) = if (!(dappRunning)) | |
377 | 377 | then throw(maintenanceMSG) | |
378 | 378 | else { | |
379 | - | let isSponsored = valueOrElse(checkWhitelist((toString(addressFromPublicKey(fromBase58String(pubKey))) + "_free_txs")), 0) | |
379 | + | let isSponsored = if ((pubKey != "")) | |
380 | + | then valueOrElse(checkWhitelist((toString(addressFromPublicKey(fromBase58String(pubKey))) + "_free_txs")), 0) | |
381 | + | else 0 | |
380 | 382 | let caller = if (if (if ((toBase58String(i.caller.bytes) == toString(this))) | |
381 | 383 | then (size(i.payments) == 0) | |
382 | 384 | else false) | |
383 | 385 | then (isSponsored > 0) | |
384 | 386 | else false) | |
385 | 387 | then toString(addressFromPublicKey(fromBase58String(pubKey))) | |
386 | 388 | else toBase58String(i.caller.bytes) | |
387 | 389 | let get_sponsored_waves = if ((pubKey != "")) | |
388 | 390 | then invoke(whitelistDapp, "useFreeTx", [toString(addressFromPublicKey(fromBase58String(pubKey)))], nil) | |
389 | 391 | else unit | |
390 | 392 | if ((get_sponsored_waves == get_sponsored_waves)) | |
391 | 393 | then $Tuple4(toBase58String(i.transactionId), caller, lastBlock.timestamp, (isSponsored > 0)) | |
392 | 394 | else throw("Strict value is not equal to itself.") | |
393 | 395 | } | |
394 | 396 | ||
395 | 397 | ||
396 | 398 | func idCallerDate (i) = if (!(dappRunning)) | |
397 | 399 | then throw(maintenanceMSG) | |
398 | 400 | else $Tuple3(toBase58String(i.transactionId), toBase58String(i.caller.bytes), lastBlock.timestamp) | |
399 | 401 | ||
400 | 402 | ||
401 | 403 | func buyMint (i,artId,issuer,bidId,bidOwner) = { | |
402 | - | let $ | |
403 | - | let id = $ | |
404 | - | let caller = $ | |
405 | - | let date = $ | |
404 | + | let $t01294713006 = idCallerDate(i) | |
405 | + | let id = $t01294713006._1 | |
406 | + | let caller = $t01294713006._2 | |
407 | + | let date = $t01294713006._3 | |
406 | 408 | let isBid = if (if (if ((caller == issuer)) | |
407 | 409 | then (bidOwner != "") | |
408 | 410 | else false) | |
409 | 411 | then (bidId != "") | |
410 | 412 | else false) | |
411 | 413 | then true | |
412 | 414 | else false | |
413 | 415 | let blockEnd = getIntegerByKey(keyEndSale(caller, artId)) | |
414 | 416 | if (if (if ((blockEnd != 0)) | |
415 | 417 | then (height >= blockEnd) | |
416 | 418 | else false) | |
417 | 419 | then !(isBid) | |
418 | 420 | else false) | |
419 | 421 | then throw("Sale ended.") | |
420 | 422 | else { | |
421 | 423 | let callerIsIssuer = (caller == issuer) | |
422 | 424 | let totalNFT = getIntegerByKey("total_nft_issued") | |
423 | 425 | let signID = getStringByKey(keySignID(issuer, artId)) | |
424 | 426 | let artworkName = getStringByKey(keyName(issuer, artId)) | |
425 | 427 | if ((artworkName == "")) | |
426 | 428 | then throw("Art doesn't exist") | |
427 | 429 | else { | |
428 | 430 | let isOnSale = getBooleanByKey(keyOnSale(issuer, artId)) | |
429 | 431 | let amountSold = getIntegerByKey(keyIssued(issuer, artId)) | |
430 | 432 | let artworkPrice = if (callerIsIssuer) | |
431 | 433 | then (currentCertificationPrice * 2) | |
432 | 434 | else getIntegerByKey(keyPrice(issuer, artId)) | |
433 | 435 | let priceAssetId = if (callerIsIssuer) | |
434 | 436 | then toBase58String(signAssetId) | |
435 | 437 | else getStringByKey(keyAssetIdAccepted(issuer, artId)) | |
436 | 438 | let maxCanSell = getIntegerByKey(keyMaxMint(issuer, artId)) | |
437 | 439 | if (if (if (!(isBid)) | |
438 | 440 | then !(callerIsIssuer) | |
439 | 441 | else false) | |
440 | 442 | then if (if ((0 >= artworkPrice)) | |
441 | 443 | then true | |
442 | 444 | else !(isOnSale)) | |
443 | 445 | then true | |
444 | 446 | else (0 >= maxCanSell) | |
445 | 447 | else false) | |
446 | 448 | then throw("Art not for sale") | |
447 | 449 | else if (if (if (!(isBid)) | |
448 | 450 | then callerIsIssuer | |
449 | 451 | else false) | |
450 | 452 | then (0 >= maxCanSell) | |
451 | 453 | else false) | |
452 | 454 | then throw("Max issuable not set") | |
453 | 455 | else { | |
454 | 456 | let checkUser = validateUser(issuer) | |
455 | 457 | if (if (isBid) | |
456 | 458 | then (checkUser != "") | |
457 | 459 | else false) | |
458 | 460 | then throw(checkUser) | |
459 | 461 | else { | |
460 | 462 | let bidDataKey = ((((((("bid_" + artId) + "_") + issuer) + "_") + bidOwner) + "_") + bidId) | |
461 | - | let $ | |
463 | + | let $t01470914876 = if (isBid) | |
462 | 464 | then getPriceAssetIdFromBid(bidDataKey) | |
463 | 465 | else validatePriceAssetId(i, priceAssetId, artworkPrice) | |
464 | - | let amount = $ | |
465 | - | let assetId = $ | |
466 | + | let amount = $t01470914876._1 | |
467 | + | let assetId = $t01470914876._2 | |
466 | 468 | let agent = valueOrElse(getString(userDapp, keyArtistAgentAddr(issuer)), feeReceiver) | |
467 | 469 | let agentShare = valueOrElse(getInteger(userDapp, keyPrimaryShare(issuer)), 0) | |
468 | 470 | let isWhitelisted = checkWhitelist(issuer) | |
469 | 471 | let cut = if ((isWhitelisted > height)) | |
470 | 472 | then 0 | |
471 | 473 | else if ((assetId == signAssetId)) | |
472 | 474 | then signCut | |
473 | 475 | else usdnWaveCut | |
474 | 476 | let amountForSign = fraction(amount, cut, 100) | |
475 | 477 | let amountForAgent = if (if (if ((agent != feeReceiver)) | |
476 | 478 | then (agentShare > 0) | |
477 | 479 | else false) | |
478 | 480 | then (height > isWhitelisted) | |
479 | 481 | else false) | |
480 | 482 | then fraction(amount, agentShare, 100) | |
481 | 483 | else 0 | |
482 | 484 | let amountForCreator = (amount - amountForSign) | |
483 | 485 | if ((amountSold == maxCanSell)) | |
484 | 486 | then throw("Art sold out") | |
485 | 487 | else { | |
486 | 488 | let newAmountSold = (amountSold + 1) | |
487 | 489 | let issueMeta = ((((((((((("Creator: " + issuer) + ", | |
488 | 490 | ArtID: ") + artId) + ", | |
489 | 491 | SignID: ") + signID) + ", | |
490 | 492 | Artwork name: ") + artworkName) + ", | |
491 | 493 | Issue: ") + toString(newAmountSold)) + "/") + toString(maxCanSell)) | |
492 | 494 | let issueNFT = Issue(("SA_" + toString((totalNFT + 1))), issueMeta, 1, 0, false) | |
493 | 495 | let idNFT = calculateAssetId(issueNFT) | |
494 | 496 | let sellStatus = if (if ((newAmountSold == maxCanSell)) | |
495 | 497 | then true | |
496 | 498 | else !(isOnSale)) | |
497 | 499 | then false | |
498 | 500 | else true | |
499 | 501 | let receiveNFT = if (if (if ((caller == issuer)) | |
500 | 502 | then (bidOwner != "") | |
501 | 503 | else false) | |
502 | 504 | then (bidId != "") | |
503 | 505 | else false) | |
504 | 506 | then addressFromStringValue(bidOwner) | |
505 | 507 | else i.caller | |
506 | 508 | let assetIdBid = if (!(isDefined(assetId))) | |
507 | 509 | then "WAVES" | |
508 | 510 | else toBase58String(value(assetId)) | |
509 | 511 | let bidData = getStringByKey((bidDataKey + "_OPEN")) | |
510 | 512 | let bidDelOld = DeleteEntry((bidDataKey + "_OPEN")) | |
511 | 513 | let bidUpdate = StringEntry((bidDataKey + "_CLOSED"), ((bidData + "_") + toString(date))) | |
512 | 514 | let soldKey = ((((((("art_sold_" + toString(newAmountSold)) + "_of_") + toString(maxCanSell)) + "_") + artId) + "_") + issuer) | |
513 | 515 | let soldValue = if (!(isBid)) | |
514 | 516 | then ((((((((((caller + "_") + toString(date)) + "_") + id) + "_") + toString(artworkPrice)) + "_") + priceAssetId) + "_") + toBase58String(idNFT)) | |
515 | 517 | else ((((((((((toString(receiveNFT) + "_") + toString(date)) + "_") + id) + "_") + toString(amount)) + "_") + assetIdBid) + "_") + toBase58String(idNFT)) | |
516 | 518 | let soldData = StringEntry(soldKey, soldValue) | |
517 | 519 | let commissions = if ((amountForAgent != 0)) | |
518 | 520 | then [ScriptTransfer(Address(fromBase58String(feeReceiver)), (amountForSign - amountForAgent), assetId), ScriptTransfer(Address(fromBase58String(agent)), amountForAgent, assetId)] | |
519 | 521 | else [ScriptTransfer(Address(fromBase58String(feeReceiver)), amountForSign, assetId)] | |
520 | 522 | let buyRes = ([IntegerEntry(keyIssued(issuer, artId), newAmountSold), StringEntry(("nft_" + toBase58String(idNFT)), soldKey), IntegerEntry("total_nft_issued", (totalNFT + 1)), IntegerEntry(keyEndSale(issuer, artId), 0), BooleanEntry(keyOnSale(issuer, artId), sellStatus), issueNFT, ScriptTransfer(Address(fromBase58String(issuer)), amountForCreator, assetId), ScriptTransfer(receiveNFT, 1, idNFT)] ++ commissions) | |
521 | 523 | if (isBid) | |
522 | 524 | then [soldData, bidUpdate, bidDelOld] :: buyRes | |
523 | 525 | else soldData :: buyRes | |
524 | 526 | } | |
525 | 527 | } | |
526 | 528 | } | |
527 | 529 | } | |
528 | 530 | } | |
529 | 531 | } | |
530 | 532 | ||
531 | 533 | ||
532 | 534 | func asString (bv) = match bv { | |
533 | 535 | case bv0: String => | |
534 | 536 | bv0 | |
535 | 537 | case _ => | |
536 | 538 | throw("Sponsored Public Key String expected") | |
537 | 539 | } | |
538 | 540 | ||
539 | 541 | ||
540 | 542 | @Callable(invoke) | |
541 | 543 | func setConf (key,val) = { | |
542 | 544 | let caller = toString(invoke.caller) | |
543 | 545 | if (containsElement([chris, toString(this)], caller)) | |
544 | 546 | then if (contains(key, "conf_")) | |
545 | 547 | then [StringEntry(key, val)] | |
546 | 548 | else throw("Entries starting with conf_ only") | |
547 | 549 | else throw("You are not allowed to change this") | |
548 | 550 | } | |
549 | 551 | ||
550 | 552 | ||
551 | 553 | ||
552 | 554 | @Callable(i) | |
553 | 555 | func addArtwork (sha256Hash,signID,name,description,tags,type,cidDisplay,sha256Export,cidExport,sha256Licence,cidLicence,crawler,royalties,pubKey) = { | |
554 | - | let $ | |
555 | - | let artId = $ | |
556 | - | let caller = $ | |
557 | - | let date = $ | |
558 | - | let isSponsored = $ | |
556 | + | let $t01890918982 = idCallerDateSponsored(i, pubKey) | |
557 | + | let artId = $t01890918982._1 | |
558 | + | let caller = $t01890918982._2 | |
559 | + | let date = $t01890918982._3 | |
560 | + | let isSponsored = $t01890918982._4 | |
559 | 561 | if (!(validateHash(sha256Hash))) | |
560 | 562 | then throw("Hash should be 64 characters maximum") | |
561 | 563 | else { | |
562 | - | let $ | |
563 | - | let licenceCID = $ | |
564 | - | let licenceHash = $ | |
564 | + | let $t01908319152 = setLIcence(cidLicence, sha256Licence) | |
565 | + | let licenceCID = $t01908319152._1 | |
566 | + | let licenceHash = $t01908319152._2 | |
565 | 567 | let validateArtwork = validateArtworkData(caller, cidDisplay, cidExport, licenceCID, sha256Export, licenceHash, name, description, tags, royalties) | |
566 | 568 | if ((validateArtwork != "")) | |
567 | 569 | then throw("Something went wrong!") | |
568 | 570 | else { | |
569 | 571 | let whitelisted_drop = (checkWhitelist((caller + "_free_drops")) > 0) | |
570 | - | let $ | |
572 | + | let $t01945119535 = if (whitelisted_drop) | |
571 | 573 | then $Tuple2(0, signID) | |
572 | 574 | else validatePayment(i) | |
573 | - | let amount = $ | |
574 | - | let assetId = $ | |
575 | + | let amount = $t01945119535._1 | |
576 | + | let assetId = $t01945119535._2 | |
575 | 577 | if (!(isDefined(amount))) | |
576 | 578 | then throw("Something went wrong") | |
577 | 579 | else { | |
578 | 580 | let entryExist = getStringByKey(keyTxidByHashOwner(sha256Hash, caller)) | |
579 | 581 | if ((entryExist != "")) | |
580 | 582 | then throw("You already added it") | |
581 | 583 | else { | |
582 | 584 | let hashExist = getStringByKey(keyOwnerByHash(sha256Hash)) | |
583 | 585 | if ((hashExist != "")) | |
584 | 586 | then throw("Hash already registered") | |
585 | 587 | else { | |
586 | 588 | let isSignCertified = checkSignCertificate(signID, caller, sha256Hash) | |
587 | 589 | if (!(isSignCertified)) | |
588 | 590 | then throw("Sign Certificate not found for this address.") | |
589 | 591 | else { | |
590 | 592 | let decrease_whitelist_drop = if (whitelisted_drop) | |
591 | 593 | then invoke(whitelistDapp, "useFreeDrop", [caller], nil) | |
592 | 594 | else unit | |
593 | 595 | if ((decrease_whitelist_drop == decrease_whitelist_drop)) | |
594 | 596 | then { | |
595 | 597 | let txToCaller = if (isSponsored) | |
596 | 598 | then [ScriptTransfer(Address(fromBase58String(caller)), 0, unit)] | |
597 | 599 | else nil | |
598 | 600 | ([StringEntry(keyOwnerByHash(sha256Hash), caller), StringEntry(keyTxidByHashOwner(sha256Hash, caller), artId), IntegerEntry(keyDate(caller, artId), date), StringEntry(keyName(caller, artId), name), StringEntry(keyDesc(caller, artId), description), StringEntry(keyDisplayCid(caller, artId), cidDisplay), StringEntry(keyExportCid(caller, artId), cidExport), StringEntry(keyExportHash(caller, artId), sha256Export), StringEntry(keyLicenceHash(caller, artId), licenceHash), StringEntry(keyLicenceCid(caller, artId), licenceCID), StringEntry(keyType(caller, artId), type), StringEntry(keyTags(caller, artId), tags), IntegerEntry(keyMaxMint(caller, artId), 0), StringEntry(keySignID(caller, artId), signID), IntegerEntry(keyIssued(caller, artId), 0), BooleanEntry(keyOnSale(caller, artId), false), StringEntry(keyidBySignid(caller, signID), artId), StringEntry(keyHashByTxidAddr(caller, artId), sha256Hash), StringEntry(keyCrawler(caller, artId), crawler), IntegerEntry(keyRoyalties(caller, artId), royalties), ScriptTransfer(Address(fromBase58String(feeReceiver)), amount, signAssetId)] ++ txToCaller) | |
599 | 601 | } | |
600 | 602 | else throw("Strict value is not equal to itself.") | |
601 | 603 | } | |
602 | 604 | } | |
603 | 605 | } | |
604 | 606 | } | |
605 | 607 | } | |
606 | 608 | } | |
607 | 609 | } | |
608 | 610 | ||
609 | 611 | ||
610 | 612 | ||
611 | 613 | @Callable(i) | |
612 | 614 | func updateArtwork (txid,name,description,tags,type,cidDisplay,sha256Export,cidExport,sha256Licence,cidLicence,crawler,royalties,pubKey) = if (!(dappRunning)) | |
613 | 615 | then throw(maintenanceMSG) | |
614 | 616 | else { | |
615 | - | let $ | |
616 | - | let id = $ | |
617 | - | let caller = $ | |
618 | - | let date = $ | |
619 | - | let isSponsored = $ | |
620 | - | let $ | |
621 | - | let licenceCID = $ | |
622 | - | let licenceHash = $ | |
617 | + | let $t02256922639 = idCallerDateSponsored(i, pubKey) | |
618 | + | let id = $t02256922639._1 | |
619 | + | let caller = $t02256922639._2 | |
620 | + | let date = $t02256922639._3 | |
621 | + | let isSponsored = $t02256922639._4 | |
622 | + | let $t02264922718 = setLIcence(cidLicence, sha256Licence) | |
623 | + | let licenceCID = $t02264922718._1 | |
624 | + | let licenceHash = $t02264922718._2 | |
623 | 625 | let validateArtwork = validateArtworkData(caller, cidDisplay, cidExport, licenceCID, sha256Export, licenceHash, name, description, tags, royalties) | |
624 | 626 | if ((validateArtwork != "")) | |
625 | 627 | then throw("Something went wrong!") | |
626 | 628 | else { | |
627 | 629 | let entryExist = getStringByKey(keyName(caller, txid)) | |
628 | 630 | if ((entryExist == "")) | |
629 | 631 | then throw("Entry not found") | |
630 | 632 | else { | |
631 | 633 | let flag = getStringByKey(keyFlag(caller, txid)) | |
632 | 634 | if ((flag == "ILLEGAL")) | |
633 | 635 | then throw("Cannot update ILLEGAL artwork") | |
634 | 636 | else if (!(isArtMinted(caller, txid))) | |
635 | 637 | then { | |
636 | 638 | let txToCaller = if (isSponsored) | |
637 | 639 | then [ScriptTransfer(Address(fromBase58String(caller)), 0, unit)] | |
638 | 640 | else nil | |
639 | 641 | ([StringEntry(keyName(caller, txid), name), StringEntry(keyDesc(caller, txid), description), StringEntry(keyDisplayCid(caller, txid), cidDisplay), StringEntry(keyExportCid(caller, txid), cidExport), StringEntry(keyExportHash(caller, txid), sha256Export), StringEntry(keyLicenceCid(caller, txid), licenceCID), StringEntry(keyLicenceHash(caller, txid), licenceHash), StringEntry(keyTags(caller, txid), tags), StringEntry(keyType(caller, txid), type), StringEntry(keyCrawler(caller, txid), crawler), IntegerEntry(keyRoyalties(caller, txid), royalties)] ++ txToCaller) | |
640 | 642 | } | |
641 | 643 | else throw("Already minted") | |
642 | 644 | } | |
643 | 645 | } | |
644 | 646 | } | |
645 | 647 | ||
646 | 648 | ||
647 | 649 | ||
648 | 650 | @Callable(i) | |
649 | 651 | func flagArtwork (artId,addr,flag,note) = { | |
650 | - | let $ | |
651 | - | let id = $ | |
652 | - | let caller = $ | |
652 | + | let $t02434524379 = idCallerDate(i) | |
653 | + | let id = $t02434524379._1 | |
654 | + | let caller = $t02434524379._2 | |
653 | 655 | if (containsElement([chris, toString(this)], caller)) | |
654 | 656 | then if (containsElement(["CONSENT", "", "CHANGE_REQUIRED", "FLAGGED", "ILLEGAL"], flag)) | |
655 | 657 | then [StringEntry(keyFlag(addr, artId), flag), StringEntry(keyNote(addr, artId), note)] | |
656 | 658 | else throw(("Unknow status " + flag)) | |
657 | 659 | else throw("You are not allowed") | |
658 | 660 | } | |
659 | 661 | ||
660 | 662 | ||
661 | 663 | ||
662 | 664 | @Callable(i) | |
663 | 665 | func deleteArtwork (artId,addr) = { | |
664 | - | let $ | |
665 | - | let id = $ | |
666 | - | let caller = $ | |
666 | + | let $t02481524849 = idCallerDate(i) | |
667 | + | let id = $t02481524849._1 | |
668 | + | let caller = $t02481524849._2 | |
667 | 669 | let addrToUse = if (containsElement([chris, toString(this)], caller)) | |
668 | 670 | then addr | |
669 | 671 | else caller | |
670 | 672 | let entryExist = valueOrErrorMessage(getStringByKey(keyName(addrToUse, artId)), "No art matching for this address") | |
671 | 673 | if ((entryExist == "")) | |
672 | 674 | then throw("No art matching for this address") | |
673 | 675 | else { | |
674 | 676 | let sha256Hash = getStringByKey(keyHashByTxidAddr(addrToUse, artId)) | |
675 | 677 | if ((sha256Hash == "")) | |
676 | 678 | then throw("No art hash matching for this address") | |
677 | 679 | else { | |
678 | 680 | let signID = getStringByKey(keySignID(addrToUse, artId)) | |
679 | 681 | if ((signID == "")) | |
680 | 682 | then throw("No SIGN ID matching") | |
681 | 683 | else { | |
682 | 684 | let dataToDelete = [DeleteEntry(keyDate(addrToUse, artId)), DeleteEntry(keyName(addrToUse, artId)), DeleteEntry(keyDesc(addrToUse, artId)), DeleteEntry(keyDisplayCid(addrToUse, artId)), DeleteEntry(keyExportCid(addrToUse, artId)), DeleteEntry(keyExportHash(addrToUse, artId)), DeleteEntry(keyLicenceHash(addrToUse, artId)), DeleteEntry(keyLicenceCid(addrToUse, artId)), DeleteEntry(keyType(addrToUse, artId)), DeleteEntry(keyTags(addrToUse, artId)), DeleteEntry(keyMaxMint(addrToUse, artId)), DeleteEntry(keySignID(addrToUse, artId)), DeleteEntry(keyIssued(addrToUse, artId)), DeleteEntry(keyOnSale(addrToUse, artId)), DeleteEntry(keyFlag(addrToUse, artId)), DeleteEntry(keyPrice(addrToUse, artId)), DeleteEntry(keyAssetIdAccepted(addrToUse, artId)), DeleteEntry(keyOwnerByHash(sha256Hash)), DeleteEntry(keyidBySignid(addrToUse, signID)), DeleteEntry(keyTxidByHashOwner(sha256Hash, addrToUse)), DeleteEntry(keyEndSale(addrToUse, artId)), DeleteEntry(keyNote(addrToUse, artId)), DeleteEntry(keyCrawler(addrToUse, artId)), DeleteEntry(keyRoyalties(addrToUse, artId))] | |
683 | 685 | if (!(isArtMinted(addrToUse, artId))) | |
684 | 686 | then if (!(dappRunning)) | |
685 | 687 | then throw(maintenanceMSG) | |
686 | 688 | else dataToDelete | |
687 | 689 | else if (containsElement([chris, toString(this)], caller)) | |
688 | 690 | then dataToDelete | |
689 | 691 | else throw("Art already minted, you cannot delete it") | |
690 | 692 | } | |
691 | 693 | } | |
692 | 694 | } | |
693 | 695 | } | |
694 | 696 | ||
695 | 697 | ||
696 | 698 | ||
697 | 699 | @Callable(i) | |
698 | 700 | func sellArtwork (artId,price,maxMint,assetId,blockEnd,pubKey) = { | |
699 | - | let $ | |
700 | - | let id = $ | |
701 | - | let caller = $ | |
702 | - | let date = $ | |
703 | - | let isSponsored = $ | |
701 | + | let $t02768527755 = idCallerDateSponsored(i, pubKey) | |
702 | + | let id = $t02768527755._1 | |
703 | + | let caller = $t02768527755._2 | |
704 | + | let date = $t02768527755._3 | |
705 | + | let isSponsored = $t02768527755._4 | |
704 | 706 | let artworkName = getStringByKey(keyName(caller, artId)) | |
705 | 707 | if ((artworkName == "")) | |
706 | 708 | then throw("This art doesn't match your account") | |
707 | 709 | else { | |
708 | 710 | let flag = getStringByKey(keyFlag(caller, artId)) | |
709 | 711 | if (containsElement(["CHANGE_REQUIRED", "FLAGGED", "ILLEGAL"], flag)) | |
710 | 712 | then throw("Flagged artwork") | |
711 | 713 | else { | |
712 | 714 | let bidNbr = getIntegerByKey(("current_bidamount_" + artId)) | |
713 | 715 | if ((0 > blockEnd)) | |
714 | 716 | then throw("Negative end") | |
715 | 717 | else if (if ((blockEnd > 0)) | |
716 | 718 | then if ((maxMint != 1)) | |
717 | 719 | then true | |
718 | 720 | else (price != 0) | |
719 | 721 | else false) | |
720 | 722 | then throw("Timed offer only allowed for unique edition and offer only") | |
721 | 723 | else { | |
722 | 724 | let baseHeight = if ((blockEnd == 0)) | |
723 | 725 | then 0 | |
724 | 726 | else height | |
725 | 727 | if (!(acceptedAssetIds(assetId))) | |
726 | 728 | then throw("Something went wrong!") | |
727 | 729 | else if (!(validateMinSell(assetId, price))) | |
728 | 730 | then throw("Something went wrong!") | |
729 | 731 | else { | |
730 | 732 | let checkUser = validateUser(caller) | |
731 | 733 | if ((checkUser != "")) | |
732 | 734 | then throw(checkUser) | |
733 | 735 | else { | |
734 | 736 | let amountSold = getIntegerByKey(keyIssued(caller, artId)) | |
735 | 737 | let maxCanSell = getIntegerByKey(keyMaxMint(caller, artId)) | |
736 | 738 | if ((maxMint > 100)) | |
737 | 739 | then throw("100 editions max per artwork") | |
738 | 740 | else if (if ((amountSold != 0)) | |
739 | 741 | then (amountSold == maxCanSell) | |
740 | 742 | else false) | |
741 | 743 | then throw("Max edition reached.") | |
742 | 744 | else if (if ((amountSold > 0)) | |
743 | 745 | then (maxCanSell != maxMint) | |
744 | 746 | else false) | |
745 | 747 | then throw("Cannot change maximum issuable anymore") | |
746 | 748 | else if (if ((bidNbr > 0)) | |
747 | 749 | then (maxCanSell != maxMint) | |
748 | 750 | else false) | |
749 | 751 | then throw("Cannot change maximum issuable with active orders") | |
750 | 752 | else { | |
751 | 753 | let sellStatus = if (if ((price > 0)) | |
752 | 754 | then (maxMint > 0) | |
753 | 755 | else false) | |
754 | 756 | then true | |
755 | 757 | else false | |
756 | 758 | let txToCaller = if (isSponsored) | |
757 | 759 | then [ScriptTransfer(Address(fromBase58String(caller)), 0, unit)] | |
758 | 760 | else nil | |
759 | 761 | ([BooleanEntry(keyOnSale(caller, artId), sellStatus), IntegerEntry(keyPrice(caller, artId), price), IntegerEntry(keyMaxMint(caller, artId), maxMint), StringEntry(keyAssetIdAccepted(caller, artId), assetId), IntegerEntry(keyEndSale(caller, artId), (baseHeight + blockEnd))] ++ txToCaller) | |
760 | 762 | } | |
761 | 763 | } | |
762 | 764 | } | |
763 | 765 | } | |
764 | 766 | } | |
765 | 767 | } | |
766 | 768 | } | |
767 | 769 | ||
768 | 770 | ||
769 | 771 | ||
770 | 772 | @Callable(i) | |
771 | 773 | func buyArtwork (artId,issuer) = buyMint(i, artId, issuer, "", "") | |
772 | 774 | ||
773 | 775 | ||
774 | 776 | ||
775 | 777 | @Callable(i) | |
776 | 778 | func setBid (artId,issuer) = { | |
777 | - | let $ | |
778 | - | let id = $ | |
779 | - | let caller = $ | |
780 | - | let date = $ | |
781 | - | let $ | |
782 | - | let payment = $ | |
783 | - | let amount = $ | |
779 | + | let $t03013330173 = idCallerDate(i) | |
780 | + | let id = $t03013330173._1 | |
781 | + | let caller = $t03013330173._2 | |
782 | + | let date = $t03013330173._3 | |
783 | + | let $t03017830214 = isPayment(i) | |
784 | + | let payment = $t03017830214._1 | |
785 | + | let amount = $t03017830214._2 | |
784 | 786 | let assetId = if (!(isDefined(payment.assetId))) | |
785 | 787 | then "WAVES" | |
786 | 788 | else toBase58String(value(payment.assetId)) | |
787 | 789 | let blockEnd = getIntegerByKey(keyEndSale(issuer, artId)) | |
788 | 790 | if (if ((blockEnd != 0)) | |
789 | 791 | then (height >= blockEnd) | |
790 | 792 | else false) | |
791 | 793 | then throw("Sale ended.") | |
792 | 794 | else { | |
793 | 795 | let bidNbr = getIntegerByKey(("current_bidamount_" + artId)) | |
794 | 796 | if (!(acceptedAssetIds(assetId))) | |
795 | 797 | then throw("asset not accepted") | |
796 | 798 | else if (!(validateMinSell(assetId, amount))) | |
797 | 799 | then throw("Wrong min sell") | |
798 | 800 | else { | |
799 | 801 | let amountSold = getIntegerByKey(keyIssued(issuer, artId)) | |
800 | 802 | let maxCanSell = getIntegerByKey(keyMaxMint(issuer, artId)) | |
801 | 803 | if ((0 >= maxCanSell)) | |
802 | 804 | then throw("No max edition set for this artwork") | |
803 | 805 | else if ((amountSold >= maxCanSell)) | |
804 | 806 | then throw("Sold out, you cannot bid") | |
805 | 807 | else [StringEntry((((((((("bid_" + artId) + "_") + issuer) + "_") + caller) + "_") + id) + "_OPEN"), ((((assetId + "_") + toString(amount)) + "_") + toString(date))), IntegerEntry(("current_bidamount_" + artId), (bidNbr + 1))] | |
806 | 808 | } | |
807 | 809 | } | |
808 | 810 | } | |
809 | 811 | ||
810 | 812 | ||
811 | 813 | ||
812 | 814 | @Callable(i) | |
813 | 815 | func acceptBid (artId,issuer,bidId,bidOwner) = { | |
814 | - | let $ | |
815 | - | let id = $ | |
816 | - | let caller = $ | |
817 | - | let date = $ | |
816 | + | let $t03137231412 = idCallerDate(i) | |
817 | + | let id = $t03137231412._1 | |
818 | + | let caller = $t03137231412._2 | |
819 | + | let date = $t03137231412._3 | |
818 | 820 | if ((caller != issuer)) | |
819 | 821 | then throw("You cannot do this action") | |
820 | 822 | else buyMint(i, artId, issuer, bidId, bidOwner) | |
821 | 823 | } | |
822 | 824 | ||
823 | 825 | ||
824 | 826 | ||
825 | 827 | @Callable(i) | |
826 | 828 | func cancelBid (artId,issuer,bidId,bidOwner) = { | |
827 | - | let $ | |
828 | - | let id = $ | |
829 | - | let caller = $ | |
830 | - | let date = $ | |
829 | + | let $t03163831699 = idCallerDate(i) | |
830 | + | let id = $t03163831699._1 | |
831 | + | let caller = $t03163831699._2 | |
832 | + | let date = $t03163831699._3 | |
831 | 833 | if (if ((caller != bidOwner)) | |
832 | 834 | then (caller != issuer) | |
833 | 835 | else false) | |
834 | 836 | then throw("You cannot do this action") | |
835 | 837 | else { | |
836 | 838 | let returnMoneyTo = if ((caller == issuer)) | |
837 | 839 | then bidOwner | |
838 | 840 | else caller | |
839 | 841 | let bidNbr = getIntegerByKey(("current_bidamount_" + artId)) | |
840 | 842 | let bidDataKey = ((((((("bid_" + artId) + "_") + issuer) + "_") + bidOwner) + "_") + bidId) | |
841 | 843 | let bidData = getStringByKey((bidDataKey + "_OPEN")) | |
842 | 844 | if ((bidData == "")) | |
843 | 845 | then throw("Bid not found") | |
844 | 846 | else { | |
845 | 847 | let bidDataArr = split(bidData, "_") | |
846 | 848 | let assetId = getBidAssetId(bidDataArr[0]) | |
847 | 849 | let bidStatus = "CANCELED" | |
848 | 850 | [DeleteEntry((bidDataKey + "_OPEN")), StringEntry(((bidDataKey + "_") + bidStatus), ((bidData + "_") + toString(date))), IntegerEntry(("current_bidamount_" + artId), (bidNbr - 1)), ScriptTransfer(Address(fromBase58String(returnMoneyTo)), parseIntValue(bidDataArr[1]), assetId)] | |
849 | 851 | } | |
850 | 852 | } | |
851 | 853 | } | |
852 | 854 | ||
853 | 855 | ||
854 | 856 | @Verifier(tx) | |
855 | 857 | func verifier () = match tx { | |
856 | 858 | case inv: InvokeScriptTransaction => | |
857 | 859 | if (if (if ((inv.function == "addArtwork")) | |
858 | 860 | then (inv.dApp == this) | |
859 | 861 | else false) | |
860 | 862 | then (inv.fee == 500000) | |
861 | 863 | else false) | |
862 | 864 | then sigVerify(tx.bodyBytes, tx.proofs[0], fromBase58String(asString(inv.args[13]))) | |
863 | 865 | else if (if (if ((inv.function == "updateArtwork")) | |
864 | 866 | then (inv.dApp == this) | |
865 | 867 | else false) | |
866 | 868 | then (inv.fee == 500000) | |
867 | 869 | else false) | |
868 | 870 | then sigVerify(tx.bodyBytes, tx.proofs[0], fromBase58String(asString(inv.args[12]))) | |
869 | 871 | else if (if (if ((inv.function == "sellArtwork")) | |
870 | 872 | then (inv.dApp == this) | |
871 | 873 | else false) | |
872 | 874 | then (inv.fee == 500000) | |
873 | 875 | else false) | |
874 | 876 | then sigVerify(tx.bodyBytes, tx.proofs[0], fromBase58String(asString(inv.args[5]))) | |
875 | 877 | else sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey) | |
876 | 878 | case _ => | |
877 | 879 | sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey) | |
878 | 880 | } | |
879 | 881 |
github/deemru/w8io/169f3d6 132.18 ms ◑