tx · Gqu3b52CXNR3mGHo68RGGkD3kdXfMqQPv8yY77f6amd4 3N5hQm6twVhFgf8mKBkJpNhxwcBnpZsPyni: -0.01400000 Waves 2019.08.19 13:40 [637922] smart account 3N5hQm6twVhFgf8mKBkJpNhxwcBnpZsPyni > SELF 0.00000000 Waves
{ "type": 13, "id": "Gqu3b52CXNR3mGHo68RGGkD3kdXfMqQPv8yY77f6amd4", "fee": 1400000, "feeAssetId": null, "timestamp": 1566211293932, "version": 1, "sender": "3N5hQm6twVhFgf8mKBkJpNhxwcBnpZsPyni", "senderPublicKey": "5qEf6v7n4Cm55KWEaSs76eUft3uwLezLoJeBrf6u9BKE", "proofs": [ "3hovMmzBVKKaF3eyL2qgjqhx7NdmRD9U8GTsUZ1aYNtzuKxAP2DCpozztYdGUXVBFwxhBvzGLaDwEcWmqowchW29" ], "script": "base64:AAIDAAAAAAAAAAAAAAAGAAAAAAhvd25lcktleQIAAAAFb3duZXIAAAAACndhdmVzVG9rZW4FAAAABHVuaXQBAAAACXBheW1lbnRPZgAAAAEAAAADa2V5CQABLAAAAAICAAAAC3BheW1lbnRfb2ZfBQAAAANrZXkBAAAACHN0YXR1c09mAAAAAQAAAANrZXkJAAEsAAAAAgIAAAAKc3RhdHVzX29mXwUAAAADa2V5AAAAAAVvd25lcgkBAAAAHEBleHRyVXNlcihhZGRyZXNzRnJvbVN0cmluZykAAAABCQEAAAAFdmFsdWUAAAABCQAEHQAAAAIFAAAABHRoaXMFAAAACG93bmVyS2V5AQAAABBpc1BheW1lbnRQZW5kaW5nAAAAAQAAAANrZXkEAAAAByRtYXRjaDAJAAQdAAAAAgUAAAAEdGhpcwkAASwAAAACAgAAAApzdGF0dXNfb2ZfBQAAAANrZXkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAABlN0cmluZwQAAAABcwUAAAAHJG1hdGNoMAkAAAAAAAACBQAAAAFzAgAAAAdwZW5kaW5nBwAAAAQAAAABaQEAAAAEaW5pdAAAAAIAAAAFb3duZXIAAA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wJAAACAAAAAQkAASwAAAACAgAAABhjYW4gb25seSBXQVZFUywgYnV0IGdvdCAJAAJYAAAAAQkBAAAABXZhbHVlAAAAAQgFAAAAAWEAAAAHYXNzZXRJZAkAAAIAAAABAgAAACdwYXltZW50IGluIGFzc2V0VG9rZW5zIG11c3QgYmUgYXR0YWNoZWQJAAACAAAAAQIAAAAoT3JkZXIgYWxyZWFkeSBoYXMgYmVlbiBwYXllZCBvciByZWplY3RlZAAAAAFpAQAAAAZyZWplY3QAAAABAAAAA2tleQMJAQAAABBpc1BheW1lbnRQZW5kaW5nAAAAAQUAAAADa2V5CQEAAAAIV3JpdGVTZXQAAAABCQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACCQEAAAAIc3RhdHVzT2YAAAABBQAAAANrZXkCAAAACHJlamVjdGVkBQAAAANuaWwJAAACAAAAAQIAAAAoT3JkZXIgYWxyZWFkeSBoYXMgYmVlbiBwYXllZCBvciByZWplY3RlZAAAAABtQ1Th", "chainId": 84, "height": 637922, "spentComplexity": 0 } View: original | compacted Prev: 3e6Bga7CzLMkTJuXavTNXRLmdY1SgkMogbavgDxf38r1 Next: 8Q7sFAGDunFcNEJeScbPWLpHEJwcUsx2ZTALCAf1DLXR Diff:
Old | New | Differences | |
---|---|---|---|
37 | 37 | ||
38 | 38 | ||
39 | 39 | @Callable(j) | |
40 | - | func pay (d) = if ( | |
40 | + | func pay (d) = if (true) | |
41 | 41 | then { | |
42 | 42 | let h = j.payment | |
43 | 43 | if ($isInstanceOf(h, "AttachedPayment")) |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 3 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = "owner" | |
5 | 5 | ||
6 | 6 | let b = unit | |
7 | 7 | ||
8 | 8 | func c (d) = ("payment_of_" + d) | |
9 | 9 | ||
10 | 10 | ||
11 | 11 | func e (d) = ("status_of_" + d) | |
12 | 12 | ||
13 | 13 | ||
14 | 14 | let f = addressFromStringValue(value(getString(this, a))) | |
15 | 15 | ||
16 | 16 | func g (d) = { | |
17 | 17 | let h = getString(this, ("status_of_" + d)) | |
18 | 18 | if ($isInstanceOf(h, "String")) | |
19 | 19 | then { | |
20 | 20 | let i = h | |
21 | 21 | (i == "pending") | |
22 | 22 | } | |
23 | 23 | else false | |
24 | 24 | } | |
25 | 25 | ||
26 | 26 | ||
27 | 27 | @Callable(j) | |
28 | 28 | func init (f,k) = if ((j.caller == this)) | |
29 | 29 | then WriteSet([DataEntry(a, f)]) | |
30 | 30 | else throw("only dapp itself can init") | |
31 | 31 | ||
32 | 32 | ||
33 | 33 | ||
34 | 34 | @Callable(j) | |
35 | 35 | func setWaitToPayment (d,l) = WriteSet([DataEntry(e(d), "pending"), DataEntry(c(d), l)]) | |
36 | 36 | ||
37 | 37 | ||
38 | 38 | ||
39 | 39 | @Callable(j) | |
40 | - | func pay (d) = if ( | |
40 | + | func pay (d) = if (true) | |
41 | 41 | then { | |
42 | 42 | let h = j.payment | |
43 | 43 | if ($isInstanceOf(h, "AttachedPayment")) | |
44 | 44 | then { | |
45 | 45 | let m = h | |
46 | 46 | if ((m.assetId == b)) | |
47 | 47 | then { | |
48 | 48 | let n = WriteSet([DataEntry(e(d), "paid")]) | |
49 | 49 | let l = getIntegerValue(this, "payment_of_test") | |
50 | 50 | ScriptResult(n, TransferSet([ScriptTransfer(f, l, b)])) | |
51 | 51 | } | |
52 | 52 | else throw(("can only WAVES, but got " + toBase58String(value(m.assetId)))) | |
53 | 53 | } | |
54 | 54 | else throw("payment in assetTokens must be attached") | |
55 | 55 | } | |
56 | 56 | else throw("Order already has been payed or rejected") | |
57 | 57 | ||
58 | 58 | ||
59 | 59 | ||
60 | 60 | @Callable(j) | |
61 | 61 | func reject (d) = if (g(d)) | |
62 | 62 | then WriteSet([DataEntry(e(d), "rejected")]) | |
63 | 63 | else throw("Order already has been payed or rejected") | |
64 | 64 | ||
65 | 65 |
github/deemru/w8io/026f985 36.43 ms ◑