tx · ATqVN1hyv1msEYCuVS3m6zc63mq9Q5h5fFmfh4eQ19X2 3MpFYUjf9xgvz61eBjwjsj1F9mmhQjNpfJu: -0.01000000 Waves 2023.04.15 19:57 [2535909] smart account 3MpFYUjf9xgvz61eBjwjsj1F9mmhQjNpfJu > SELF 0.00000000 Waves
{ "type": 13, "id": "ATqVN1hyv1msEYCuVS3m6zc63mq9Q5h5fFmfh4eQ19X2", "fee": 1000000, "feeAssetId": null, "timestamp": 1681577909528, "version": 2, "chainId": 84, "sender": "3MpFYUjf9xgvz61eBjwjsj1F9mmhQjNpfJu", "senderPublicKey": "AsxTW2DFTyqChejTK5BZthqmoB2pX21ZJhB5R1N7LXRM", "proofs": [ "2uzLxT3GacUfNqVnyyCPPu77dNVVmi6zjiDwMgX8LoHN66jyQpwNNZnAWWsNVxDzbHHXSC23NYqzXGS1ttVzgTuj" ], "script": "base64:AAIFAAAAAAAAABcIAhIAEgMKAQESABIDCgEBEgASAwoBAQAAAAMAAAAABHVzZE4BAAAAINdSkRj0X0+lXoTbibwZKGxwezjGpc3PoC6ezdqH7+NgAAAAAAR1c2RDAQAAACD0HLk3GIOJeFIeiGiWi1sorjYJlG3kH4D2RHpd3gl4DAAAAAAFd2F2ZXMBAAAAILnzUlPjKqBuy8fo+4a2JypuPgYDalMYcMQU5JM5I/ATAAAABgAAAAFpAQAAAAp1c2ROX3N0YWtlAAAAAAMJAQAAAAIhPQAAAAIICQABkQAAAAIIBQAAAAFpAAAACHBheW1lbnRzAAAAAAAAAAAAAAAAB2Fzc2V0SWQFAAAABHVzZE4JAAACAAAAAQIAAAAQdW5leHBlY3RlZCBhc3NldAQAAAAQY3VycmVudExpcXVpZGl0eQkBAAAAC3ZhbHVlT3JFbHNlAAAAAgkABBoAAAACBQAAAAR0aGlzCQAEJQAAAAEIBQAAAAFpAAAADG9yaWdpbkNhbGxlcgAAAAAAAAAAAAkABEwAAAACCQEAAAAMSW50ZWdlckVudHJ5AAAAAgkABCUAAAABCAUAAAABa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AxvcmlnaW5DYWxsZXIFAAAABmFtb3VudAkABEwAAAACCQEAAAAOU2NyaXB0VHJhbnNmZXIAAAADCAUAAAABaQAAAAxvcmlnaW5DYWxsZXIFAAAABmFtb3VudAUAAAAEdXNkQwUAAAADbmlsCQAAAgAAAAECAAAADnRvbyBiaWcgYW1vdW50AAAAAWkBAAAAC3dhdmVzX3N0YWtlAAAAAAMJAQAAAAIhPQAAAAIICQABkQAAAAIIBQAAAAFpAAAACHBheW1lbnRzAAAAAAAAAAAAAAAAB2Fzc2V0SWQFAAAABXdhdmVzCQAAAgAAAAECAAAAEHVuZXhwZWN0ZWQgYXNzZXQEAAAAEGN1cnJlbnRMaXF1aWRpdHkJAQAAAAt2YWx1ZU9yRWxzZQAAAAIJAAQaAAAAAgUAAAAEdGhpcwkABCUAAAABCAUAAAABaQAAAAxvcmlnaW5DYWxsZXIAAAAAAAAAAAAJAARMAAAAAgkBAAAADEludGVnZXJFbnRyeQAAAAIJAAQlAAAAAQgFAAAAAWkAAAAMb3JpZ2luQ2FsbGVyCQAAZAAAAAIFAAAAEGN1cnJlbnRMaXF1aWRpdHkICQABkQAAAAIIBQAAAAFpAAAACHBheW1lbnRzAAAAAAAAAAAAAAAABmFtb3VudAUAAAADbmlsAAAAAWkBAAAAEXdhdmVzX2NhbmNlbFN0YWtlAAAAAQAAAAZhbW91bnQDCQAAZwAAAAIJAQAAABFAZXh0ck5hdGl2ZSgxMDUwKQAAAAIFAAAABHRoaXMJAAQlAAAAAQgFAAAAAWkAAAAMb3JpZ2luQ2FsbGVyBQAAAAZhbW91bnQJAARMAAAAAgkBAAAADlNjcmlwdFRyYW5zZmVyAAAAAwgFAAAAAWkAAAAMb3JpZ2luQ2FsbGVyBQAAAAZhbW91bnQFAAAABXdhdmVzBQAAAANuaWwJAAACAAAAAQIAAAAOdG9vIGJpZyBhbW91bnQAAAAAQyprpA==", "height": 2535909, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 4i4VficJqq3DjSidDZ67sCEWG7hnnZTyWUcXy1pMWkwK Next: none Full:
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let usdN = base58'FVXgJ86erBw5GAMeAw1CnYXwQn48BFAEAhRyHPUjbMQB' | |
5 | 5 | ||
6 | 6 | let usdC = base58'HRut8ESAGXxwvsKJky1V96qRtqyXQd4Apq4GY7TE5yGP' | |
7 | 7 | ||
8 | 8 | let waves = base58'DWscu6nt8HMVq3kR8ySucpjKPpPpAJs2H3mqgpLa6bQW' | |
9 | 9 | ||
10 | 10 | @Callable(i) | |
11 | 11 | func usdN_stake () = if ((i.payments[0].assetId != usdN)) | |
12 | 12 | then throw("unexpected asset") | |
13 | 13 | else { | |
14 | 14 | let currentLiquidity = valueOrElse(getInteger(this, toString(i.originCaller)), 0) | |
15 | 15 | [IntegerEntry(toString(i.originCaller), (currentLiquidity + i.payments[0].amount))] | |
16 | 16 | } | |
17 | 17 | ||
18 | 18 | ||
19 | 19 | ||
20 | 20 | @Callable(i) | |
21 | 21 | func usdN_cancelStake (amount) = if ((getIntegerValue(this, toString(i.originCaller)) >= amount)) | |
22 | 22 | then [ScriptTransfer(i.originCaller, amount, usdN)] | |
23 | 23 | else throw("too big amount") | |
24 | 24 | ||
25 | 25 | ||
26 | 26 | ||
27 | 27 | @Callable(i) | |
28 | 28 | func usdC_stake () = if ((i.payments[0].assetId != usdC)) | |
29 | 29 | then throw("unexpected asset") | |
30 | 30 | else { | |
31 | 31 | let currentLiquidity = valueOrElse(getInteger(this, toString(i.originCaller)), 0) | |
32 | 32 | [IntegerEntry(toString(i.originCaller), (currentLiquidity + i.payments[0].amount))] | |
33 | 33 | } | |
34 | 34 | ||
35 | 35 | ||
36 | 36 | ||
37 | 37 | @Callable(i) | |
38 | 38 | func usdC_cancelStake (amount) = if ((getIntegerValue(this, toString(i.originCaller)) >= amount)) | |
39 | 39 | then [ScriptTransfer(i.originCaller, amount, usdC)] | |
40 | 40 | else throw("too big amount") | |
41 | 41 | ||
42 | 42 | ||
43 | 43 | ||
44 | 44 | @Callable(i) | |
45 | 45 | func waves_stake () = if ((i.payments[0].assetId != waves)) | |
46 | 46 | then throw("unexpected asset") | |
47 | 47 | else { | |
48 | 48 | let currentLiquidity = valueOrElse(getInteger(this, toString(i.originCaller)), 0) | |
49 | 49 | [IntegerEntry(toString(i.originCaller), (currentLiquidity + i.payments[0].amount))] | |
50 | 50 | } | |
51 | 51 | ||
52 | 52 | ||
53 | 53 | ||
54 | 54 | @Callable(i) | |
55 | 55 | func waves_cancelStake (amount) = if ((getIntegerValue(this, toString(i.originCaller)) >= amount)) | |
56 | 56 | then [ScriptTransfer(i.originCaller, amount, waves)] | |
57 | 57 | else throw("too big amount") | |
58 | 58 | ||
59 | 59 |
github/deemru/w8io/169f3d6 23.48 ms ◑