tx · 7HTPJoMsyRS7bNJQHEqgvYaLerny5V2owN2i2CkEyeA1 3Mup4uG7mXS2N9Fuk3JtEpoKKmzA2PtQcUY: -0.01400000 Waves 2019.09.24 09:51 [690099] smart account 3Mup4uG7mXS2N9Fuk3JtEpoKKmzA2PtQcUY > SELF 0.00000000 Waves
{ "type": 13, "id": "7HTPJoMsyRS7bNJQHEqgvYaLerny5V2owN2i2CkEyeA1", "fee": 1400000, "feeAssetId": null, "timestamp": 1569307942988, "version": 1, "sender": "3Mup4uG7mXS2N9Fuk3JtEpoKKmzA2PtQcUY", "senderPublicKey": "6VdgiscuZ9B1c2urnAVPPVaCS5afNjzf1RpG2SS3GUy6", "proofs": [ "48FpVz3VYXucSAuDQ3tdRUgknrf3Cn2JnXCTe7tC8urXnB2GgwcNhE1tWteotjq69WP27pkXsxwWD2DDcE1X5taW" ], "script": "base64:AAIDAAAAAAAAAAAAAAADAAAAAA1hY2NlcHRlZFRva2VuAQAAACDopWq8yndC8nBhMjVKT0WDubke5ZlnF8Nx6tkLoQSt6wAAAAAMY3VycmVudFByaWNlAAAAAFF9oCwAAAAAAARiYW5rAgAAACMzTjFFNnRYZGRSb1ZhUmZROWRRM3ZnNUxhVzJmc2Q4SEt1YgAAAAIAAAAGaW52b2tlAQAAABFmaWxlQ2VydGlmaWNhdGlvbgAAAAQAAAAEaGFzaAAAAAV0aXRsZQAAAAl0aW1lc3RhbXAAAAAEdXVpZAQAAAAHcGF5bWVudAkBAAAAB2V4dHJhY3QAAAABCAUAAAAGaW52b2tlAAAAB3BheW1lbnQEAAAABmFtb3VudAkBAAAAB2V4dHJhY3QAAAABCAUAAAAHcGF5bWVudAAAAAZhbW91bnQEAAAAAmlkCQEAAAAHZXh0cmFjdAAAAAEIBQAAAAZpbnZva2UAAAANdHJhbnNhY3Rpb25JZAQAAAAKZW50cnlFeGlzdAQAAAAHJG1hdGNoMAkABB0AAAACBQAAAAR0aGlzCQABLAAAAAIJAAEsAAAAAgUAAAAEaGFzaAI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AAABmNhbGxlcgAAAAVieXRlcwUAAAAEZGF0YQkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgkAASwAAAACCQABLAAAAAIJAAEsAAAAAgIAAAAFaGFzaF8JAAJYAAAAAQUAAAACaWQCAAAAAV8JAAJYAAAAAQgIBQAAAAZpbnZva2UAAAAGY2FsbGVyAAAABWJ5dGVzBQAAAARoYXNoBQAAAANuaWwJAQAAAAtUcmFuc2ZlclNldAAAAAEJAARMAAAAAgkBAAAADlNjcmlwdFRyYW5zZmVyAAAAAwkBAAAAHEBleHRyVXNlcihhZGRyZXNzRnJvbVN0cmluZykAAAABBQAAAARiYW5rBQAAAAZhbW91bnQFAAAADWFjY2VwdGVkVG9rZW4FAAAAA25pbAAAAABFvJPx", "chainId": 84, "height": 690099, "spentComplexity": 0 } View: original | compacted Prev: 3QHfLGjZJPqW5QLD2PNjyp9je3GHAJCf2DHEHBjdBRLx Next: Dv9zBtX2HYdBs2d24SNFwg1y1eB5RBu6L5zEnqBxiHKb Diff:
Old | New | Differences | |
---|---|---|---|
8 | 8 | let c = "3N1E6tXddRoVaRfQ9dQ3vg5LaW2fsd8HKub" | |
9 | 9 | ||
10 | 10 | @Callable(d) | |
11 | - | func fileCertification (e,f,g) = { | |
12 | - | let | |
13 | - | let | |
14 | - | let | |
15 | - | let | |
16 | - | let | |
17 | - | if ($isInstanceOf( | |
11 | + | func fileCertification (e,f,g,h) = { | |
12 | + | let i = extract(d.payment) | |
13 | + | let j = extract(i.amount) | |
14 | + | let k = extract(d.transactionId) | |
15 | + | let l = { | |
16 | + | let m = getString(this, ((e + "_") + h)) | |
17 | + | if ($isInstanceOf(m, "String")) | |
18 | 18 | then { | |
19 | - | let | |
20 | - | | |
19 | + | let n = m | |
20 | + | n | |
21 | 21 | } | |
22 | 22 | else "NONE" | |
23 | 23 | } | |
24 | - | if (( | |
24 | + | if ((l != "NONE")) | |
25 | 25 | then throw("This entry already exist") | |
26 | 26 | else { | |
27 | - | let | |
28 | - | then extract( | |
27 | + | let o = if (isDefined(i.assetId)) | |
28 | + | then extract(i.assetId) | |
29 | 29 | else throw("Waves is not accepted as payment") | |
30 | - | if (( | |
30 | + | if ((o != a)) | |
31 | 31 | then throw("Only payments in SIGN are allowed at the moment") | |
32 | - | else if (( | |
32 | + | else if ((j != b)) | |
33 | 33 | then throw("The price is wrong") | |
34 | - | else ScriptResult(WriteSet([DataEntry(("sender_" + toBase58String(j)), toBase58String(d.caller.bytes)), DataEntry(((e + "_") + g), toBase58String(j)), DataEntry(((("title_" + toBase58String(j)) + "_") + toBase58String(d.caller.bytes)), f), DataEntry(((("hash_" + toBase58String(j)) + "_") + toBase58String(d.caller.bytes)), e)]), TransferSet([ScriptTransfer(addressFromStringValue(c), i, a)])) | |
34 | + | else ScriptResult(WriteSet([DataEntry(((e + "_") + h), toBase58String(k)), DataEntry(((("timestamp" + toBase58String(k)) + "_") + toBase58String(d.caller.bytes)), g), DataEntry(((("title_" + toBase58String(k)) + "_") + toBase58String(d.caller.bytes)), f), DataEntry(((("hash_" + toBase58String(k)) + "_") + toBase58String(d.caller.bytes)), e)]), TransferSet([ScriptTransfer(addressFromStringValue(c), j, a)])) | |
35 | + | } | |
36 | + | } | |
37 | + | ||
38 | + | ||
39 | + | ||
40 | + | @Callable(d) | |
41 | + | func fileCertificationJson (e,f,g,h,p) = { | |
42 | + | let i = extract(d.payment) | |
43 | + | let j = extract(i.amount) | |
44 | + | let k = extract(d.transactionId) | |
45 | + | let l = { | |
46 | + | let m = getString(this, ((e + "_") + h)) | |
47 | + | if ($isInstanceOf(m, "String")) | |
48 | + | then { | |
49 | + | let n = m | |
50 | + | n | |
51 | + | } | |
52 | + | else "NONE" | |
53 | + | } | |
54 | + | if ((l != "NONE")) | |
55 | + | then throw("This entry already exist") | |
56 | + | else { | |
57 | + | let o = if (isDefined(i.assetId)) | |
58 | + | then extract(i.assetId) | |
59 | + | else throw("Waves is not accepted as payment") | |
60 | + | if ((o != a)) | |
61 | + | then throw("Only payments in SIGN are allowed at the moment") | |
62 | + | else if ((j != b)) | |
63 | + | then throw("The price is wrong") | |
64 | + | else ScriptResult(WriteSet([DataEntry(((e + "_") + h), toBase58String(k)), DataEntry(((("timestamp" + toBase58String(k)) + "_") + toBase58String(d.caller.bytes)), g), DataEntry(((("title_" + toBase58String(k)) + "_") + toBase58String(d.caller.bytes)), f), DataEntry(((("data_" + toBase58String(k)) + "_") + toBase58String(d.caller.bytes)), p), DataEntry(((("hash_" + toBase58String(k)) + "_") + toBase58String(d.caller.bytes)), e)]), TransferSet([ScriptTransfer(addressFromStringValue(c), j, a)])) | |
35 | 65 | } | |
36 | 66 | } | |
37 | 67 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 3 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = base58'Gf9t8FA4H3ssoZPCwrg3KwUFCci8zuUFP9ssRsUY3s6a' | |
5 | 5 | ||
6 | 6 | let b = 350000000000 | |
7 | 7 | ||
8 | 8 | let c = "3N1E6tXddRoVaRfQ9dQ3vg5LaW2fsd8HKub" | |
9 | 9 | ||
10 | 10 | @Callable(d) | |
11 | - | func fileCertification (e,f,g) = { | |
12 | - | let | |
13 | - | let | |
14 | - | let | |
15 | - | let | |
16 | - | let | |
17 | - | if ($isInstanceOf( | |
11 | + | func fileCertification (e,f,g,h) = { | |
12 | + | let i = extract(d.payment) | |
13 | + | let j = extract(i.amount) | |
14 | + | let k = extract(d.transactionId) | |
15 | + | let l = { | |
16 | + | let m = getString(this, ((e + "_") + h)) | |
17 | + | if ($isInstanceOf(m, "String")) | |
18 | 18 | then { | |
19 | - | let | |
20 | - | | |
19 | + | let n = m | |
20 | + | n | |
21 | 21 | } | |
22 | 22 | else "NONE" | |
23 | 23 | } | |
24 | - | if (( | |
24 | + | if ((l != "NONE")) | |
25 | 25 | then throw("This entry already exist") | |
26 | 26 | else { | |
27 | - | let | |
28 | - | then extract( | |
27 | + | let o = if (isDefined(i.assetId)) | |
28 | + | then extract(i.assetId) | |
29 | 29 | else throw("Waves is not accepted as payment") | |
30 | - | if (( | |
30 | + | if ((o != a)) | |
31 | 31 | then throw("Only payments in SIGN are allowed at the moment") | |
32 | - | else if (( | |
32 | + | else if ((j != b)) | |
33 | 33 | then throw("The price is wrong") | |
34 | - | else ScriptResult(WriteSet([DataEntry(("sender_" + toBase58String(j)), toBase58String(d.caller.bytes)), DataEntry(((e + "_") + g), toBase58String(j)), DataEntry(((("title_" + toBase58String(j)) + "_") + toBase58String(d.caller.bytes)), f), DataEntry(((("hash_" + toBase58String(j)) + "_") + toBase58String(d.caller.bytes)), e)]), TransferSet([ScriptTransfer(addressFromStringValue(c), i, a)])) | |
34 | + | else ScriptResult(WriteSet([DataEntry(((e + "_") + h), toBase58String(k)), DataEntry(((("timestamp" + toBase58String(k)) + "_") + toBase58String(d.caller.bytes)), g), DataEntry(((("title_" + toBase58String(k)) + "_") + toBase58String(d.caller.bytes)), f), DataEntry(((("hash_" + toBase58String(k)) + "_") + toBase58String(d.caller.bytes)), e)]), TransferSet([ScriptTransfer(addressFromStringValue(c), j, a)])) | |
35 | + | } | |
36 | + | } | |
37 | + | ||
38 | + | ||
39 | + | ||
40 | + | @Callable(d) | |
41 | + | func fileCertificationJson (e,f,g,h,p) = { | |
42 | + | let i = extract(d.payment) | |
43 | + | let j = extract(i.amount) | |
44 | + | let k = extract(d.transactionId) | |
45 | + | let l = { | |
46 | + | let m = getString(this, ((e + "_") + h)) | |
47 | + | if ($isInstanceOf(m, "String")) | |
48 | + | then { | |
49 | + | let n = m | |
50 | + | n | |
51 | + | } | |
52 | + | else "NONE" | |
53 | + | } | |
54 | + | if ((l != "NONE")) | |
55 | + | then throw("This entry already exist") | |
56 | + | else { | |
57 | + | let o = if (isDefined(i.assetId)) | |
58 | + | then extract(i.assetId) | |
59 | + | else throw("Waves is not accepted as payment") | |
60 | + | if ((o != a)) | |
61 | + | then throw("Only payments in SIGN are allowed at the moment") | |
62 | + | else if ((j != b)) | |
63 | + | then throw("The price is wrong") | |
64 | + | else ScriptResult(WriteSet([DataEntry(((e + "_") + h), toBase58String(k)), DataEntry(((("timestamp" + toBase58String(k)) + "_") + toBase58String(d.caller.bytes)), g), DataEntry(((("title_" + toBase58String(k)) + "_") + toBase58String(d.caller.bytes)), f), DataEntry(((("data_" + toBase58String(k)) + "_") + toBase58String(d.caller.bytes)), p), DataEntry(((("hash_" + toBase58String(k)) + "_") + toBase58String(d.caller.bytes)), e)]), TransferSet([ScriptTransfer(addressFromStringValue(c), j, a)])) | |
35 | 65 | } | |
36 | 66 | } | |
37 | 67 | ||
38 | 68 |
github/deemru/w8io/169f3d6 37.09 ms ◑