tx · HTetfZZiA7vFeT91uCTDuxoUx13w4TWvkhDE1ZXZc9B1 3NBGebxfi8arSFesWFZmHiZbUTaL1LN3K2n: -0.01000000 Waves 2019.07.03 06:28 [568690] smart account 3NBGebxfi8arSFesWFZmHiZbUTaL1LN3K2n > SELF 0.00000000 Waves
{ "type": 13, "id": "HTetfZZiA7vFeT91uCTDuxoUx13w4TWvkhDE1ZXZc9B1", "fee": 1000000, "feeAssetId": null, "timestamp": 1562124532390, "version": 1, "sender": "3NBGebxfi8arSFesWFZmHiZbUTaL1LN3K2n", "senderPublicKey": "GQuxeXLbjWe44XSJX8GXHEfPmd7e97QeNz3uvV5CVddH", "proofs": [ "4P7sgs8pgiZUYVq78bBjsBsBAhmY61BGbmowi9DLjeHpfwhaL67zh1FtgSYr4hSxo9EgPRmmpn1Eh1YG5CWQaUk4" ], "script": "base64:AAIDAAAAAAAAAAAAAAAHAAAAAAROT05FAgAAAARub25lAQAAAAtnZXRTdHJCeUtleQAAAAEAAAADa2V5BAAAAANzdHIEAAAAByRtYXRjaDAJAAQdAAAAAgUAAAAEdGhpcwUAAAADa2V5AwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAAZTdHJpbmcEAAAAAWEFAAAAByRtYXRjaDAFAAAAAWEFAAAABE5PTkUFAAAAA3N0cgEAAAAKZ2V0S2V5SXRlbQAAAAIAAAAIc3VwcGxpZXIAAAAFdGl0bGUJAAEsAAAAAgIAAAAFaXRlbV8JAAJYAAAAAQkAAfcAAAABCQABmwAAAAEJAAEsAAAAAgUAAAAIc3VwcGxpZXIFAAAABXRpdGxlAQAAABJnZXRLZXlJdGVtU3VwcGxpZXIAAAABAAAABGl0ZW0JAAEsAAAAAgUAAAAEaXRlbQIAAAAGX293bmVyAQAAABRnZXRWYWx1ZUl0ZW1TdXBwbGllcgAAAAEAAAAEaXRlbQkBAAAAC2dldFN0ckJ5S2V5AAAAAQkBAAAAEmdldEtleUl0ZW1TdXBwbGllcgAAAAEFAAAABGl0ZW0BAAAAD2dldEtleUl0ZW1QcmljZQAAAAEAAAAEaXRlbQkAASwAAAACBQAAAARpdGVtAgAAAAZfcHJpY2UBAAAADmdldEtleUl0ZW1EYXRhAAAAAQAAAARpdGVtCQABLAAAAAIFAAAABGl0ZW0CAAAABV9kYXRhAAAAAQAAAAFpAQAAAAdhZGRJdGVtAAAAAwAAAAV0aXRsZQAAAAVwcmljZQAAAARkYXRhBAAAAA9zdXBwbGllckFkZHJlc3MJAAJYAAAAAQgIBQAAAAFpAAAABmNhbGxlcgAAAAVieXRlcwQAAAAEaXRlbQkBAAAACmdldEtleUl0ZW0AAAACBQAAAA9zdXBwbGllckFkZHJlc3MFAAAABXRpdGxlAwkAAGcAAAACAAAAAAAAAAAABQAAAAVwcmljZQkAAAIAAAABAgAAAC5wdXJjaGFzZSBhbW91bnQgY2Fubm90IGJlIGxlc3MgdGhhbiBpdGVtIHByaWNlAwkBAAAAAiE9AAAAAgkBAAAAFGdldFZhbHVlSXRlbVN1cHBsaWVyAAAAAQUAAAAEaXRlbQUAAAAETk9ORQkAAAIAAAABAgAAABhhbiBpdGVtIGlzIGFscmVhZHkgZXhpc3QJAQAAAAhXcml0ZVNldAAAAAEJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIJAQAAABJnZXRLZXlJdGVtU3VwcGxpZXIAAAABBQAAAARpdGVtBQAAAA9zdXBwbGllckFkZHJlc3MJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIJAQAAAA9nZXRLZXlJdGVtUHJpY2UAAAABBQAAAARpdGVtBQAAAAVwcmljZQkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgkBAAAADmdldEtleUl0ZW1EYXRhAAAAAQUAAAAEaXRlbQUAAAAEZGF0YQUAAAADbmlsAAAAAPHX5m0=", "chainId": 84, "height": 568690, "spentComplexity": 0 } View: original | compacted Prev: none Next: CQfmQUMaVRoA9ce4mFyzTwctbKk1EYxSEvKw6oyEfV3M Full:
Old | New | Differences | |
---|---|---|---|
1 | - | # no script | |
1 | + | {-# STDLIB_VERSION 3 #-} | |
2 | + | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | + | {-# CONTENT_TYPE DAPP #-} | |
4 | + | let a = "none" | |
5 | + | ||
6 | + | func b (c) = { | |
7 | + | let d = { | |
8 | + | let e = getString(this, c) | |
9 | + | if ($isInstanceOf(e, "String")) | |
10 | + | then { | |
11 | + | let f = e | |
12 | + | f | |
13 | + | } | |
14 | + | else a | |
15 | + | } | |
16 | + | d | |
17 | + | } | |
18 | + | ||
19 | + | ||
20 | + | func g (h,i) = ("item_" + toBase58String(sha256(toBytes((h + i))))) | |
21 | + | ||
22 | + | ||
23 | + | func j (k) = (k + "_owner") | |
24 | + | ||
25 | + | ||
26 | + | func l (k) = b(j(k)) | |
27 | + | ||
28 | + | ||
29 | + | func m (k) = (k + "_price") | |
30 | + | ||
31 | + | ||
32 | + | func n (k) = (k + "_data") | |
33 | + | ||
34 | + | ||
35 | + | @Callable(o) | |
36 | + | func addItem (i,p,q) = { | |
37 | + | let r = toBase58String(o.caller.bytes) | |
38 | + | let k = g(r, i) | |
39 | + | if ((0 >= p)) | |
40 | + | then throw("purchase amount cannot be less than item price") | |
41 | + | else if ((l(k) != a)) | |
42 | + | then throw("an item is already exist") | |
43 | + | else WriteSet([DataEntry(j(k), r), DataEntry(m(k), p), DataEntry(n(k), q)]) | |
44 | + | } | |
45 | + | ||
46 | + |
github/deemru/w8io/026f985 14.40 ms ◑