tx · 8bwq8FdCd7WLjzR7LavyAy8jvmsyZLq8jRBvQi9HGH9F

3N58U7hA1kzMTCUqHiJGdcPdjxAKspMgGNp:  -0.01000000 Waves

2021.07.16 16:31 [1616224] smart account 3N58U7hA1kzMTCUqHiJGdcPdjxAKspMgGNp > SELF 0.00000000 Waves

{ "type": 13, "id": "8bwq8FdCd7WLjzR7LavyAy8jvmsyZLq8jRBvQi9HGH9F", "fee": 1000000, "feeAssetId": null, "timestamp": 1626442320055, "version": 2, "chainId": 84, "sender": "3N58U7hA1kzMTCUqHiJGdcPdjxAKspMgGNp", "senderPublicKey": "85gydchvWB9gMPFCKM6kfLPWFSATbtGog2Y6rUjhtQKT", "proofs": [ "PFZpuepWenv6sGkQqQBFpMXxPMQVfP2NF2MX9mzMCnnEcN99miPCLCu6z766rtStvFCBcwnsx4EJGmpdeNdv4F6" ], "script": "base64:AAIDAAAAAAAAAAkIARIAEgMKAQEAAAAAAAAAAgAAAAFpAQAAAAdkZXBvc2l0AAAAAAQAAAAJc3dhcFRva2VuAQAAACBvje/AxUXc2eIfb1BtN6afnbACpt3QImOf1zkflBhsKAQAAAADcG10CQEAAAAHZXh0cmFjdAAAAAEIBQAAAAFpAAAAB3BheW1lbnQDCQEAAAAJaXNEZWZpbmVkAAAAAQgFAAAAA3BtdAAAAAdhc3NldElkCQAAAgAAAAECAAAAIWNhbiBob2RsIHdhdmVzIG9ubHkgYXQgdGhlIG1vbWVudAQAAAAKY3VycmVudEtleQkAAlgAAAABCAgFAAAAAWkAAAAGY2FsbGVyAAAABWJ5dGVzBAAAAA1jdXJyZW50QW1vdW50BAAAAAckbWF0Y2gwCQAEGgAAAAIFAAAABHRoaXMFAAAACmN1cnJlbnRLZXkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAA0ludAQAAAABYQUAAAAHJG1hdGNoMAUAAAABYQAAAAAAAAAAAAQAAAAJbmV3QW1vdW50CQAAZAAAAAIFAAAADWN1cnJlbnRBbW91bnQIBQAAAANwbXQAAAAGYW1vdW50CQEAAAALVHJhbnNmZXJTZXQAAAABCQAETAAAAAIJAQAAAA5TY3JpcHRUcmFuc2ZlcgAAAAMIBQAAAAFpAAAABmNhbGxlcgUAAAAJbmV3QW1vdW50BQAAAAlzd2FwVG9rZW4FAAAAA25pbAAAAAFpAQAAAAh3aXRoZHJhdwAAAAEAAAAGYW1vdW50BAAAAAlzd2FwVG9rZW4BAAAAGgFUpuGHDWW6ayML/sFv6HpdBDFFJLgYCuBFBAAAAApjdXJyZW50S2V5CQACWAAAAAEICAUAAAABaQAAAAZjYWxsZXIAAAAFYnl0ZXMEAAAADWN1cnJlbnRBbW91bnQEAAAAByRtYXRjaDAJAAQaAAAAAgUAAAAEdGhpcwUAAAAKY3VycmVudEtleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAADSW50BAAAAAFhBQAAAAckbWF0Y2gwBQAAAAFhAAAAAAAAAAAABAAAAAluZXdBbW91bnQJAABlAAAAAgUAAAANY3VycmVudEFtb3VudAUAAAAGYW1vdW50AwkAAGYAAAACAAAAAAAAAAAABQAAAAZhbW91bnQJAAACAAAAAQIAAAAeQ2FuJ3Qgd2l0aGRyYXcgbmVnYXRpdmUgYW1vdW50AwkAAGYAAAACAAAAAAAAAAAABQAAAAluZXdBbW91bnQJAAACAAAAAQIAAAASTm90IGVub3VnaCBiYWxhbmNlCQEAAAAMU2NyaXB0UmVzdWx0AAAAAgkBAAAACFdyaXRlU2V0AAAAAQkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgUAAAAKY3VycmVudEtleQUAAAAJbmV3QW1vdW50BQAAAANuaWwJAQAAAAtUcmFuc2ZlclNldAAAAAEJAARMAAAAAgkBAAAADlNjcmlwdFRyYW5zZmVyAAAAAwgFAAAAAWkAAAAGY2FsbGVyBQAAAAZhbW91bnQFAAAACXN3YXBUb2tlbgUAAAADbmlsAAAAAE/74rg=", "height": 1616224, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: FrVvPTCtnqpJUSNCojefZuno4FbUdRoMNqhbj6Y1iX9j Next: 4kgLm4Z8B3qDrdytaQSYq1e7KtpmWFaGGguBaUjxAWfJ Diff:
OldNewDifferences
55
66 @Callable(i)
77 func deposit () = {
8- let swapToken = base58'3N58U7hA1kzMTCUqHiJGdcPdjxAKspMgGNp'
8+ let swapToken = base58'8WTnTr8QxFYKhMo7tkjLigfw2zAFFQYzjpoNdSFruTL3'
99 let pmt = extract(i.payment)
1010 if (isDefined(pmt.assetId))
1111 then throw("can hodl waves only at the moment")
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44
55
66 @Callable(i)
77 func deposit () = {
8- let swapToken = base58'3N58U7hA1kzMTCUqHiJGdcPdjxAKspMgGNp'
8+ let swapToken = base58'8WTnTr8QxFYKhMo7tkjLigfw2zAFFQYzjpoNdSFruTL3'
99 let pmt = extract(i.payment)
1010 if (isDefined(pmt.assetId))
1111 then throw("can hodl waves only at the moment")
1212 else {
1313 let currentKey = toBase58String(i.caller.bytes)
1414 let currentAmount = match getInteger(this, currentKey) {
1515 case a: Int =>
1616 a
1717 case _ =>
1818 0
1919 }
2020 let newAmount = (currentAmount + pmt.amount)
2121 TransferSet([ScriptTransfer(i.caller, newAmount, swapToken)])
2222 }
2323 }
2424
2525
2626
2727 @Callable(i)
2828 func withdraw (amount) = {
2929 let swapToken = base58'3N58U7hA1kzMTCUqHiJGdcPdjxAKspMgGNp'
3030 let currentKey = toBase58String(i.caller.bytes)
3131 let currentAmount = match getInteger(this, currentKey) {
3232 case a: Int =>
3333 a
3434 case _ =>
3535 0
3636 }
3737 let newAmount = (currentAmount - amount)
3838 if ((0 > amount))
3939 then throw("Can't withdraw negative amount")
4040 else if ((0 > newAmount))
4141 then throw("Not enough balance")
4242 else ScriptResult(WriteSet([DataEntry(currentKey, newAmount)]), TransferSet([ScriptTransfer(i.caller, amount, swapToken)]))
4343 }
4444
4545

github/deemru/w8io/026f985 
29.67 ms