tx · F3vHpd67uSEvtwbAKBGhE9RobFYrxAAbTa2Zh65RXWyp 3N2on7WDDVf8bbAmjkZKYVHRW4fhGSquHUm: -0.00200000 Waves 2022.09.30 20:21 [2252138] smart account 3N2on7WDDVf8bbAmjkZKYVHRW4fhGSquHUm > SELF 0.00000000 Waves
{ "type": 13, "id": "F3vHpd67uSEvtwbAKBGhE9RobFYrxAAbTa2Zh65RXWyp", "fee": 200000, "feeAssetId": null, "timestamp": 1664558508871, "version": 2, "chainId": 84, "sender": "3N2on7WDDVf8bbAmjkZKYVHRW4fhGSquHUm", "senderPublicKey": "3rEiMKu5j69JF4a1uspBife5QN3fouhQhyvcUgdxpJaS", "proofs": [ "45DbAi8obr7F5wdi1x3sbhKUHWKwkhyD9r1XnjXmFsmkeNrhPFpExeP2xhv1V5TZXSRq2T2ha83HWEhUcu35Dffv" ], "script": "base64:BgIMCAISABIAEgASABIAAQALbm9kZUFkZHJlc3MJAQV2YWx1ZQEJAKYIAQIjM01wSFJSTDVQcHZManQ5b1JIbXd4S2tXZ2lLWldYVGZZYU0FAWkBCG9uZUxlYXNlAAQKbGVhc2VFbnRyeQkAxAgCBQtub2RlQWRkcmVzcwgJAQV2YWx1ZQEJAJEDAggFAWkIcGF5bWVudHMAAAZhbW91bnQEAmlkCQC5CAEFCmxlYXNlRW50cnkJAMwIAgUKbGVhc2VFbnRyeQkAzAgCCQELQmluYXJ5RW50cnkCAgZsZWFzZTEFAmlkBQNuaWwBaQEQb25MZWFzZUFuZENhbmNlbAAEAmlkCQEFdmFsdWUBCQCcCAIFBHRoaXMCBmxlYXNlMQkAzAgCCQDECAIFC25vZGVBZGRyZXNzCAkBBXZhbHVlAQkAkQMCCAUBaQhwYXltZW50cwAABmFtb3VudAkAzAgCCQELTGVhc2VDYW5jZWwBBQJpZAUDbmlsAWkBCXR3b0xlYXNlcwAEC2xlYXNlRW50cnkxCQDECAIFC25vZGVBZGRyZXNzCQBpAggJAQV2YWx1ZQEJAJEDAggFAWkIcGF5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zAAAIBQJ0eA9zZW5kZXJQdWJsaWNLZXm7/rgE", "height": 2252138, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: none Next: none Full:
Old | New | Differences | |
---|---|---|---|
1 | - | # no script | |
1 | + | {-# STDLIB_VERSION 6 #-} | |
2 | + | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | + | {-# CONTENT_TYPE DAPP #-} | |
4 | + | let nodeAddress = value(addressFromString("3MpHRRL5PpvLjt9oRHmwxKkWgiKZWXTfYaM")) | |
5 | + | ||
6 | + | @Callable(i) | |
7 | + | func oneLease () = { | |
8 | + | let leaseEntry = Lease(nodeAddress, value(i.payments[0]).amount) | |
9 | + | let id = calculateLeaseId(leaseEntry) | |
10 | + | [leaseEntry, BinaryEntry("lease1", id)] | |
11 | + | } | |
12 | + | ||
13 | + | ||
14 | + | ||
15 | + | @Callable(i) | |
16 | + | func onLeaseAndCancel () = { | |
17 | + | let id = value(getBinary(this, "lease1")) | |
18 | + | [Lease(nodeAddress, value(i.payments[0]).amount), LeaseCancel(id)] | |
19 | + | } | |
20 | + | ||
21 | + | ||
22 | + | ||
23 | + | @Callable(i) | |
24 | + | func twoLeases () = { | |
25 | + | let leaseEntry1 = Lease(nodeAddress, (value(i.payments[0]).amount / 2)) | |
26 | + | let leaseEntry2 = Lease(nodeAddress, (value(i.payments[0]).amount / 2)) | |
27 | + | let id1 = calculateLeaseId(leaseEntry1) | |
28 | + | let id2 = calculateLeaseId(leaseEntry2) | |
29 | + | [leaseEntry1, leaseEntry2, BinaryEntry("lease1", id1), BinaryEntry("lease2", id2)] | |
30 | + | } | |
31 | + | ||
32 | + | ||
33 | + | ||
34 | + | @Callable(i) | |
35 | + | func twoLeasesAndCanels () = { | |
36 | + | let id1 = value(getBinary(this, "lease1")) | |
37 | + | let id2 = value(getBinary(this, "lease2")) | |
38 | + | let leaseEntry1 = Lease(nodeAddress, (value(i.payments[0]).amount / 2)) | |
39 | + | let leaseEntry2 = Lease(nodeAddress, (value(i.payments[0]).amount / 2)) | |
40 | + | [leaseEntry1, leaseEntry2, LeaseCancel(id1), LeaseCancel(id2)] | |
41 | + | } | |
42 | + | ||
43 | + | ||
44 | + | ||
45 | + | @Callable(i) | |
46 | + | func leaseDappToDapp () = { | |
47 | + | let result = invoke(value(addressFromString("3N7eE6ZqWcFXAEPfRJN2VL1QtZQF3k86XSi")), "oneLease", nil, i.payments) | |
48 | + | if ((result == result)) | |
49 | + | then nil | |
50 | + | else throw("Strict value is not equal to itself.") | |
51 | + | } | |
52 | + | ||
53 | + | ||
54 | + | @Verifier(tx) | |
55 | + | func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey) | |
56 | + |
github/deemru/w8io/026f985 19.79 ms ◑