tx · Et4n3qHzA4SCLgzkmJZKwG2uGkAGXAtuRrXdoqRFyvyo

3N9g8vmJj171kPszhaCUyPDNfNPqaXiFP3Z:  -0.04000000 Waves

2020.06.07 19:46 [1033133] smart account 3N9g8vmJj171kPszhaCUyPDNfNPqaXiFP3Z > SELF 0.00000000 Waves

{ "type": 13, "id": "Et4n3qHzA4SCLgzkmJZKwG2uGkAGXAtuRrXdoqRFyvyo", "fee": 4000000, "feeAssetId": null, "timestamp": 1591548486253, "version": 1, "sender": "3N9g8vmJj171kPszhaCUyPDNfNPqaXiFP3Z", "senderPublicKey": "G4tSmURBD4HJkP9Q8xjQhetzYDb1J7Bc581de6M9V7AK", "proofs": [ "3wE96Whk4EmWFYY9ghviJCS4XMXjtcSyR8NQYxnHEY4NhiejmtenWyn76N8KWTw3ArU8j5TjWB6aE5S2tFz2MANz" ], "script": "base64:AAIDAAAAAAAAAAQIARIAAAAAAAAAAAEAAAABaQEAAAAIcHVyY2hhc2UAAAAABAAAAANwbXQJAQAAAAdleHRyYWN0AAAAAQgFAAAAAWkAAAAHcGF5bWVudAMJAQAAAAlpc0RlZmluZWQAAAABCAUAAAADcG10AAAAB2Fzc2V0SWQJAAACAAAAAQIAAAAgY2FuIHVzZSBXQVZFUyBvbmx5IGF0IHRoZSBtb21lbnQEAAAAD2N1c3RvbWVyQWRyZWVzcwkAAlgAAAABCAgFAAAAAWkAAAAGY2FsbGVyAAAABWJ5dGVzBAAAAAVwcmljZQQAAAAHJG1hdGNoMAkABBoAAAACBQAAAAR0aGlzAgAAABNJdGVtX0FfY291cG9uX3ByaWNlAwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAANJbnQEAAAAAWEFAAAAByRtYXRjaDAFAAAAAWEAAAAAAAAAAAADCQAAZgAAAAIFAAAABXByaWNlCAUAAAADcG10AAAABmFtb3VudAkAAAIAAAABAgAAAC5wdXJjaGFzZSBhbW91bnQgY2Fubm90IGJlIGxlc3MgdGhhbSBpdGVtIHByaWNlAwkAAGYAAAACCAUAAAADcG10AAAABmFtb3VudAUAAAAFcHJpY2UJAAACAAAAAQIAAAAwcHVyY2hhc2UgYW1vdW50IGNhbm5vdCBiZSBoaWdoZXIgdGhhbiBpdGVtIHByb2NlCQEAAAAIV3JpdGVTZXQAAAABCQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACCQABLAAAAAICAAAAIHN0YXR1czpwdXJjaGFzZV9JdGVtX0FfY3VzdG9tZXJfBQAAAA9jdXN0b21lckFkcmVlc3MCAAAACWNvbmZpcm1lZAkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgkAASwAAAACAgAAAB9wcmljZTpwdXJjaGFzZV9JdGVtX0FfY3VzdG9tZXJfBQAAAA9jdXN0b21lckFkcmVlc3MFAAAABXByaWNlBQAAAANuaWwAAAAA8TRENQ==", "chainId": 84, "height": 1033133, "spentComplexity": 0 } View: original | compacted Prev: zGKYXtPjHWS44vnEtqyaLaqzEVidpR2jnY682L6Pv2q Next: 453BXrz1QG6PHXRauBiCTQrPvD31wkC4BueWemFRheBb Diff:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
4-let alicePubKey = base58'7ULo5c4qYG7K4Zy4SFTMGzYzQ8By2hXNHAZYmoQrHtpE'
54
6-let bobPubKey = base58'G4tSmURBD4HJkP9Q8xjQhetzYDb1J7Bc581de6M9V7AK'
7-
8-let cooperPubKey = base58'B8P2fEVPKmbGP1deNKPcTxG9N3R9viSWrVdo3LiDjvkm'
95
106 @Callable(i)
117 func purchase () = {
128 let pmt = extract(i.payment)
139 if (isDefined(pmt.assetId))
14- then throw("can hodl WAVES only at the moment")
10+ then throw("can use WAVES only at the moment")
1511 else {
1612 let customerAdreess = toBase58String(i.caller.bytes)
1713 let price = match getInteger(this, "Item_A_coupon_price") {
2117 0
2218 }
2319 if ((price > pmt.amount))
24- then throw("purchase amount cannot be less them item")
20+ then throw("purchase amount cannot be less tham item price")
2521 else if ((pmt.amount > price))
26- then throw("purchase amount cannot be higher them item")
22+ then throw("purchase amount cannot be higher than item proce")
2723 else WriteSet([DataEntry(("status:purchase_Item_A_customer_" + customerAdreess), "confirmed"), DataEntry(("price:purchase_Item_A_customer_" + customerAdreess), price)])
2824 }
2925 }
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
4-let alicePubKey = base58'7ULo5c4qYG7K4Zy4SFTMGzYzQ8By2hXNHAZYmoQrHtpE'
54
6-let bobPubKey = base58'G4tSmURBD4HJkP9Q8xjQhetzYDb1J7Bc581de6M9V7AK'
7-
8-let cooperPubKey = base58'B8P2fEVPKmbGP1deNKPcTxG9N3R9viSWrVdo3LiDjvkm'
95
106 @Callable(i)
117 func purchase () = {
128 let pmt = extract(i.payment)
139 if (isDefined(pmt.assetId))
14- then throw("can hodl WAVES only at the moment")
10+ then throw("can use WAVES only at the moment")
1511 else {
1612 let customerAdreess = 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))
24- then throw("purchase amount cannot be less them item")
20+ then throw("purchase amount cannot be less tham item price")
2521 else if ((pmt.amount > price))
26- then throw("purchase amount cannot be higher them item")
22+ then throw("purchase amount cannot be higher than item proce")
2723 else WriteSet([DataEntry(("status:purchase_Item_A_customer_" + customerAdreess), "confirmed"), DataEntry(("price:purchase_Item_A_customer_" + customerAdreess), price)])
2824 }
2925 }
3026
3127

github/deemru/w8io/169f3d6 
34.05 ms