tx · 6YTo15aEUVCsjbLSpswT5qnHzKrcVS1ZAmpETzZVGJoq

3MxJx6npysQdoyyxLsCCb3Yg8fTeH3gEQQd:  -0.01000000 Waves

2023.12.04 00:49 [2871019] smart account 3MxJx6npysQdoyyxLsCCb3Yg8fTeH3gEQQd > SELF 0.00000000 Waves

{ "type": 13, "id": "6YTo15aEUVCsjbLSpswT5qnHzKrcVS1ZAmpETzZVGJoq", "fee": 1000000, "feeAssetId": null, "timestamp": 1701640256635, "version": 2, "chainId": 84, "sender": "3MxJx6npysQdoyyxLsCCb3Yg8fTeH3gEQQd", "senderPublicKey": "EEhsp9Jd5MwVmYJMGAZJL3tTb5KcurTz8Aw7wksZuw3e", "proofs": [ "3qXcHCCndKyRMfiR9c99HBsWbWaTi6Qhm3UqPST2CaL49DSUnT5E9s7izNZrZoBAdJ7fUjFRiWVMGc7yCVLgSkKu", "y4rg5yAnF95z5VAPNi3ifvyF5DKrRbbTHx9xo7xrXmwx8CGGDHbWxMWN795i8SaVCAW76rYUmDtQ3oTCRK1CDiW" ], "script": "base64:AAIDAAAAAAAAAAQIARIAAAAAAAAAAAEAAAABaQEAAAAIcHVyY2hhc2UAAAAABAAAAANwbXQJAQAAAAdleHRyYWN0AAAAAQgFAAAAAWkAAAAHcGF5bWVudAMJAQAAAAlpc0RlZmluZWQAAAABCAUAAAADcG10AAAAB2Fzc2V0SWQJAAACAAAAAQIAAAAgY2FuIHVzZSBXQVZFUyBvbmx5IGF0IHRoZSBtb21lbnQEAAAAD2N1c3RvbWVyQWRkcmVzcwkAAlgAAAABCAgFAAAAAWkAAAAGY2FsbGVyAAAABWJ5dGVzBAAAAAVwcmljZQQAAAAHJG1hdGNoMAkABBoAAAACBQAAAAR0aGlzAgAAABNpdGVtX0FfY291cG9uX3ByaWNlAwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAANJbnQEAAAAAWEFAAAAByRtYXRjaDAFAAAAAWEAAAAAAAAAAAADCQAAZgAAAAIFAAAABXByaWNlCAUAAAADcG10AAAABmFtb3VudAkAAAIAAAABAgAAAC5wdXJjaGFzZSBhbW91bnQgY2Fubm90IGJlIGxlc3MgdGhhbiBpdGVtIHByaWNlAwkAAGYAAAACCAUAAAADcG10AAAABmFtb3VudAUAAAAFcHJpY2UJAAACAAAAAQIAAAAwcHVyY2hhc2UgYW1vdW50IGNhbm5vdCBiZSBoaWdoZXIgdGhhbiBpdGVtIHByaWNlCQEAAAAIV3JpdGVTZXQAAAABCQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACCQABLAAAAAICAAAAIHN0YXR1czpwdXJjaGFzZV9pdGVtX0FfY3VzdG9tZXJfBQAAAA9jdXN0b21lckFkZHJlc3MCAAAACWNvbmZpcm1lZAkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgkAASwAAAACAgAAAB9wcmljZTpwdXJjaGFzZV9pdGVtX0FfY3VzdG9tZXJfBQAAAA9jdXN0b21lckFkZHJlc3MFAAAABXByaWNlBQAAAANuaWwAAAABAAAAAnR4AQAAAAZ2ZXJpZnkAAAAABAAAAAckbWF0Y2gwBQAAAAJ0eAMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAUU2V0U2NyaXB0VHJhbnNhY3Rpb24EAAAAAWQFAAAAByRtYXRjaDAJAAH0AAAAAwgFAAAAAnR4AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACdHgAAAAGcHJvb2ZzAAAAAAAAAAAACAUAAAACdHgAAAAPc2VuZGVyUHVibGljS2V5AwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAA9EYXRhVHJhbnNhY3Rpb24EAAAAAWQFAAAAByRtYXRjaDAGAwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAABNUcmFuc2ZlclRyYW5zYWN0aW9uBAAAAAFkBQAAAAckbWF0Y2gwBgfznwaL", "height": 2871019, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 8W9xax8GYjSzgveTNBtiF1nrXxrEQspL2nQLNWmi7cdG Next: Af5JgqvPxpTq4kFasVhPmeWSDvJdshakYPTub2Epugrf Diff:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
4-let acc1PubKey = base58'FgdjGJ4tLFiavKEKf4WkWwkgvU8ARWP1WYZfmUrXo4CY'
54
6-let acc2PubKey = base58'EEhsp9Jd5MwVmYJMGAZJL3tTb5KcurTz8Aw7wksZuw3e'
7-
8-let acc3PubKey = base58'6SdykacJeMCbeNvVJY71gWMJeXt9ZT44X4KexwZxHEYz'
95
106 @Callable(i)
117 func purchase () = {
3026
3127
3228 @Verifier(tx)
33-func verify () = {
34- let acc1_1 = sigVerify(tx.bodyBytes, tx.proofs[0], acc1PubKey)
35- let acc1_2 = sigVerify(tx.bodyBytes, tx.proofs[1], acc1PubKey)
36- let acc1_3 = sigVerify(tx.bodyBytes, tx.proofs[2], acc1PubKey)
37- let acc2_1 = sigVerify(tx.bodyBytes, tx.proofs[0], acc2PubKey)
38- let acc2_2 = sigVerify(tx.bodyBytes, tx.proofs[1], acc2PubKey)
39- let acc2_3 = sigVerify(tx.bodyBytes, tx.proofs[2], acc2PubKey)
40- let acc3_1 = sigVerify(tx.bodyBytes, tx.proofs[0], acc3PubKey)
41- let acc3_2 = sigVerify(tx.bodyBytes, tx.proofs[1], acc3PubKey)
42- let acc3_3 = sigVerify(tx.bodyBytes, tx.proofs[2], acc3PubKey)
43- let acc1acc2 = if (if (if (if (if (if (acc1_1)
44- then acc2_2
45- else false)
46- then true
47- else if (acc1_1)
48- then acc2_3
49- else false)
50- then true
51- else if (acc1_2)
52- then acc2_1
53- else false)
54- then true
55- else if (acc1_2)
56- then acc2_3
57- else false)
58- then true
59- else if (acc1_3)
60- then acc2_1
61- else false)
62- then true
63- else if (acc1_3)
64- then acc2_2
65- else false
66- let acc1acc3 = if (if (if (if (if (if (acc1_1)
67- then acc3_2
68- else false)
69- then true
70- else if (acc1_1)
71- then acc3_3
72- else false)
73- then true
74- else if (acc1_2)
75- then acc3_1
76- else false)
77- then true
78- else if (acc1_2)
79- then acc3_3
80- else false)
81- then true
82- else if (acc1_3)
83- then acc3_1
84- else false)
85- then true
86- else if (acc1_3)
87- then acc3_2
88- else false
89- let acc2acc3 = if (if (if (if (if (if (acc3_1)
90- then acc2_2
91- else false)
92- then true
93- else if (acc3_1)
94- then acc2_3
95- else false)
96- then true
97- else if (acc3_2)
98- then acc2_1
99- else false)
100- then true
101- else if (acc3_2)
102- then acc2_3
103- else false)
104- then true
105- else if (acc3_3)
106- then acc2_1
107- else false)
108- then true
109- else if (acc3_3)
110- then acc2_2
111- else false
112- match tx {
113- case d: SetScriptTransaction =>
114- if (if (acc1acc2)
115- then true
116- else acc2acc3)
117- then true
118- else acc1acc3
119- case d: DataTransaction =>
120- if (if (acc1acc2)
121- then true
122- else acc2acc3)
123- then true
124- else acc1acc3
125- case d: TransferTransaction =>
126- if (if (acc1acc2)
127- then true
128- else acc2acc3)
129- then true
130- else acc1acc3
131- case _ =>
132- false
133- }
134- }
29+func verify () = match tx {
30+ case d: SetScriptTransaction =>
31+ sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
32+ case d: DataTransaction =>
33+ true
34+ case d: TransferTransaction =>
35+ true
36+ case _ =>
37+ false
38+}
13539
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
4-let acc1PubKey = base58'FgdjGJ4tLFiavKEKf4WkWwkgvU8ARWP1WYZfmUrXo4CY'
54
6-let acc2PubKey = base58'EEhsp9Jd5MwVmYJMGAZJL3tTb5KcurTz8Aw7wksZuw3e'
7-
8-let acc3PubKey = base58'6SdykacJeMCbeNvVJY71gWMJeXt9ZT44X4KexwZxHEYz'
95
106 @Callable(i)
117 func purchase () = {
128 let pmt = extract(i.payment)
139 if (isDefined(pmt.assetId))
1410 then throw("can use WAVES only at the moment")
1511 else {
1612 let customerAddress = toBase58String(i.caller.bytes)
1713 let price = match getInteger(this, "item_A_coupon_price") {
1814 case a: Int =>
1915 a
2016 case _ =>
2117 0
2218 }
2319 if ((price > pmt.amount))
2420 then throw("purchase amount cannot be less than item price")
2521 else if ((pmt.amount > price))
2622 then throw("purchase amount cannot be higher than item price")
2723 else WriteSet([DataEntry(("status:purchase_item_A_customer_" + customerAddress), "confirmed"), DataEntry(("price:purchase_item_A_customer_" + customerAddress), price)])
2824 }
2925 }
3026
3127
3228 @Verifier(tx)
33-func verify () = {
34- let acc1_1 = sigVerify(tx.bodyBytes, tx.proofs[0], acc1PubKey)
35- let acc1_2 = sigVerify(tx.bodyBytes, tx.proofs[1], acc1PubKey)
36- let acc1_3 = sigVerify(tx.bodyBytes, tx.proofs[2], acc1PubKey)
37- let acc2_1 = sigVerify(tx.bodyBytes, tx.proofs[0], acc2PubKey)
38- let acc2_2 = sigVerify(tx.bodyBytes, tx.proofs[1], acc2PubKey)
39- let acc2_3 = sigVerify(tx.bodyBytes, tx.proofs[2], acc2PubKey)
40- let acc3_1 = sigVerify(tx.bodyBytes, tx.proofs[0], acc3PubKey)
41- let acc3_2 = sigVerify(tx.bodyBytes, tx.proofs[1], acc3PubKey)
42- let acc3_3 = sigVerify(tx.bodyBytes, tx.proofs[2], acc3PubKey)
43- let acc1acc2 = if (if (if (if (if (if (acc1_1)
44- then acc2_2
45- else false)
46- then true
47- else if (acc1_1)
48- then acc2_3
49- else false)
50- then true
51- else if (acc1_2)
52- then acc2_1
53- else false)
54- then true
55- else if (acc1_2)
56- then acc2_3
57- else false)
58- then true
59- else if (acc1_3)
60- then acc2_1
61- else false)
62- then true
63- else if (acc1_3)
64- then acc2_2
65- else false
66- let acc1acc3 = if (if (if (if (if (if (acc1_1)
67- then acc3_2
68- else false)
69- then true
70- else if (acc1_1)
71- then acc3_3
72- else false)
73- then true
74- else if (acc1_2)
75- then acc3_1
76- else false)
77- then true
78- else if (acc1_2)
79- then acc3_3
80- else false)
81- then true
82- else if (acc1_3)
83- then acc3_1
84- else false)
85- then true
86- else if (acc1_3)
87- then acc3_2
88- else false
89- let acc2acc3 = if (if (if (if (if (if (acc3_1)
90- then acc2_2
91- else false)
92- then true
93- else if (acc3_1)
94- then acc2_3
95- else false)
96- then true
97- else if (acc3_2)
98- then acc2_1
99- else false)
100- then true
101- else if (acc3_2)
102- then acc2_3
103- else false)
104- then true
105- else if (acc3_3)
106- then acc2_1
107- else false)
108- then true
109- else if (acc3_3)
110- then acc2_2
111- else false
112- match tx {
113- case d: SetScriptTransaction =>
114- if (if (acc1acc2)
115- then true
116- else acc2acc3)
117- then true
118- else acc1acc3
119- case d: DataTransaction =>
120- if (if (acc1acc2)
121- then true
122- else acc2acc3)
123- then true
124- else acc1acc3
125- case d: TransferTransaction =>
126- if (if (acc1acc2)
127- then true
128- else acc2acc3)
129- then true
130- else acc1acc3
131- case _ =>
132- false
133- }
134- }
29+func verify () = match tx {
30+ case d: SetScriptTransaction =>
31+ sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
32+ case d: DataTransaction =>
33+ true
34+ case d: TransferTransaction =>
35+ true
36+ case _ =>
37+ false
38+}
13539

github/deemru/w8io/6500d08 
31.59 ms