tx · DqMNFSoUksrzmvyfqhf9nxbp1tNePL3YaGHWCDFoE7pi 3Ms9YDMep25yKVDZmzP8PaG6vpZMyRN1kJp: -0.01000000 Waves 2022.02.17 17:43 [1927753] smart account 3Ms9YDMep25yKVDZmzP8PaG6vpZMyRN1kJp > SELF 0.00000000 Waves
{ "type": 13, "id": "DqMNFSoUksrzmvyfqhf9nxbp1tNePL3YaGHWCDFoE7pi", "fee": 1000000, "feeAssetId": null, "timestamp": 1645109032745, "version": 2, "chainId": 84, "sender": "3Ms9YDMep25yKVDZmzP8PaG6vpZMyRN1kJp", "senderPublicKey": "DBFsF67y4W1PHwv8PvsfD9mctboYQZBGGNm7EwHckCgh", "proofs": [ "3ybtrRCpPQPWuRAPHRNrpx9DXXGavEnXaPKMfsP9xjH6eqWEEoc4YSnmB8fhDrXStwMQxQ7Jaxm1naScszdqss31" ], "script": "base64:AAIFAAAAAAAAABgIAhIDCgEIEgUKAwgICBIICgYICAgICAgAAAAOAQAAAA1rZXlDb2xsZWN0aW9uAAAAAgAAAAZjYWxsZXIAAAAMY29sbGVjdGlvbklkCQABLAAAAAIJAAEsAAAAAgkAASwAAAACAgAAAAtjb2xsZWN0aW9uXwUAAAAMY29sbGVjdGlvbklkAgAAAAFfBQAAAAZjYWxsZXIBAAAAEGtleVN1YmNvbGxlY3Rpb24AAAACAAAABmNhbGxlcgAAAAxjb2xsZWN0aW9uSWQJAAEsAAAAAgkAASwAAAACCQABLAAAAAICAAAADnN1YmNvbGxlY3Rpb25fBQAAAAxjb2xsZWN0aW9uSWQCAAAAAV8FAAAABmNhbGxlcgEAAAAaa2V5U3ViY29sbGVjdGlvbkNvbGxlY3Rpb24AAAADAAAABmNhbGxlcgAAAAxjb2xsZWN0aW9uSWQAAAAKY29sbGVjdGlvbgkAASwAAAACCQABLAAAAAIJAAEsAAAAAgkAASwAAAACCQABLAAAAAICAAAAGXN1YmNvbGxlY3Rpb25fY29sbGVjdGlvbl8FAAAADGNvbGxlY3Rpb25JZAIA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QnlLZXkAAAABBQAAAAdzYWxlS2V5CQAAAgAAAAECAAAAL0NhbiBub3QgdXBkYXRlIGNvbGxlY3Rpb24gZnJvbSBhcnR3b3JrIGZvciBzYWxlBAAAAA1kZWxldGVFbnRyaWVzAwMJAQAAAAIhPQAAAAIFAAAADW9sZENvbGxlY3Rpb24FAAAACmNvbGxlY3Rpb24GCQEAAAACIT0AAAACBQAAABBvbGRTdWJjb2xsZWN0aW9uBQAAAA1zdWJjb2xsZWN0aW9uCQAETAAAAAIJAQAAAAtEZWxldGVFbnRyeQAAAAEJAQAAABprZXlTdWJjb2xsZWN0aW9uQ29sbGVjdGlvbgAAAAMFAAAABmNhbGxlcgUAAAAMY29sbGVjdGlvbklkBQAAAApjb2xsZWN0aW9uBQAAAANuaWwFAAAAA25pbAkABE4AAAACBQAAAA1kZWxldGVFbnRyaWVzCQEAAAALY29sbGVjdGlvbnMAAAAFBQAAAAxjb2xsZWN0aW9uSWQFAAAAAWkFAAAACmNvbGxlY3Rpb24FAAAADXN1YmNvbGxlY3Rpb24FAAAABmNhbGxlcgAAAABINwUG", "height": 1927753, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: none Next: CXRkV1XGgyFCDjKmG8u9Nk916kAGuncogFMEx7P2LwrB Full:
Old | New | Differences | |
---|---|---|---|
1 | - | # no script | |
1 | + | {-# STDLIB_VERSION 5 #-} | |
2 | + | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | + | {-# CONTENT_TYPE DAPP #-} | |
4 | + | func a (b,c) = ((("collection_" + c) + "_") + b) | |
5 | + | ||
6 | + | ||
7 | + | func d (b,c) = ((("subcollection_" + c) + "_") + b) | |
8 | + | ||
9 | + | ||
10 | + | func e (b,c,f) = ((((("subcollection_collection_" + c) + "_") + b) + "_") + f) | |
11 | + | ||
12 | + | ||
13 | + | func g (b,c) = ((("art_onsale_" + c) + "_") + b) | |
14 | + | ||
15 | + | ||
16 | + | let h = "sconexDapp" | |
17 | + | ||
18 | + | let i = "oracleKey" | |
19 | + | ||
20 | + | func j (k) = { | |
21 | + | let l = getString(this, k) | |
22 | + | if ($isInstanceOf(l, "String")) | |
23 | + | then { | |
24 | + | let m = l | |
25 | + | m | |
26 | + | } | |
27 | + | else "" | |
28 | + | } | |
29 | + | ||
30 | + | ||
31 | + | let n = j(i) | |
32 | + | ||
33 | + | let o = value(addressFromString(n)) | |
34 | + | ||
35 | + | let p = getStringValue(o, h) | |
36 | + | ||
37 | + | func q (k) = valueOrElse(getBoolean(addressFromStringValue(p), k), false) | |
38 | + | ||
39 | + | ||
40 | + | func r (s) = if ((s == addressFromString(p))) | |
41 | + | then true | |
42 | + | else throw("Only the sconex dapp can invoke this") | |
43 | + | ||
44 | + | ||
45 | + | func t (u,k) = valueOrElse(getString(u, k), "") | |
46 | + | ||
47 | + | ||
48 | + | func v (c,w,f,x,y) = if (if (r(w.caller)) | |
49 | + | then true | |
50 | + | else (w.caller == this)) | |
51 | + | then if ((f == "")) | |
52 | + | then throw("Collections can not be empty!") | |
53 | + | else if ((x == "")) | |
54 | + | then [StringEntry(a(y, c), f)] | |
55 | + | else [StringEntry(a(y, c), f), StringEntry(e(y, c, f), x)] | |
56 | + | else throw("Wrong invoker") | |
57 | + | ||
58 | + | ||
59 | + | @Callable(w) | |
60 | + | func initDapp (z) = if ((w.caller != this)) | |
61 | + | then throw("You cannot do this action") | |
62 | + | else if ((n != "")) | |
63 | + | then throw("oracle already set, you can't override!") | |
64 | + | else [StringEntry(i, z)] | |
65 | + | ||
66 | + | ||
67 | + | ||
68 | + | @Callable(w) | |
69 | + | func collectionProcess (f,x,y) = $Tuple2(v(toBase58String(w.transactionId), w, f, x, y), toBase58String(w.transactionId)) | |
70 | + | ||
71 | + | ||
72 | + | ||
73 | + | @Callable(w) | |
74 | + | func updateCollection (c,A,B,C,f,x) = { | |
75 | + | let b = toBase58String(w.caller.bytes) | |
76 | + | let D = g(C, b) | |
77 | + | if ((t(addressFromStringValue(p), ((("collection_" + C) + "_") + b)) != c)) | |
78 | + | then throw("This collection is not linked with the artwork") | |
79 | + | else if (q(D)) | |
80 | + | then throw("Can not update collection from artwork for sale") | |
81 | + | else { | |
82 | + | let E = if (if ((A != f)) | |
83 | + | then true | |
84 | + | else (B != x)) | |
85 | + | then [DeleteEntry(e(b, c, f))] | |
86 | + | else nil | |
87 | + | (E ++ v(c, w, f, x, b)) | |
88 | + | } | |
89 | + | } | |
90 | + | ||
91 | + |
github/deemru/w8io/169f3d6 18.27 ms ◑