tx · BSLZHBkG8bMkvTYjFYYgrin4VU8AWVeP3QuSBJsT3wtq 3Mx8raFsQfjh2JBeT8MN1Jv5sTvGkx5PDDS: -0.01000000 Waves 2023.08.26 11:16 [2727377] smart account 3Mx8raFsQfjh2JBeT8MN1Jv5sTvGkx5PDDS > SELF 0.00000000 Waves
{ "type": 13, "id": "BSLZHBkG8bMkvTYjFYYgrin4VU8AWVeP3QuSBJsT3wtq", "fee": 1000000, "feeAssetId": null, "timestamp": 1693037832329, "version": 2, "chainId": 84, "sender": "3Mx8raFsQfjh2JBeT8MN1Jv5sTvGkx5PDDS", "senderPublicKey": "HmWR8GbhBF4LAodJ9xNgR7PpWF79RuCrhPWJWxqdB1KL", "proofs": [ "32t89XBhhcgfe2vf3VL8nKEjPk4Z3KjYXzSr2tnpaXZGBkR1qQjj8Dp2AzhTSu4HWVoea9oChb85kaMFwdWsstHm" ], "script": "base64:AAIFAAAAAAAAAAQIAhIAAAAAAAAAAAEAAAABaQEAAAAQQWRkUG9vbExpcXVpZGl0eQAAAAAEAAAADWNhbGxlcmFkZHJlc3MJAAJYAAAAAQgIBQAAAAFpAAAABmNhbGxlcgAAAAVieXRlcwQAAAADcG10AwkAAAAAAAACCQABkAAAAAEIBQAAAAFpAAAACHBheW1lbnRzAAAAAAAAAAABCQABkQAAAAIIBQAAAAFpAAAACHBheW1lbnRzAAAAAAAAAAAACQAAAgAAAAECAAAASU5vIHBheW1lbnQgYXR0YWNoZWQsIFBsZWFzZSBBdHRhY2ggb25seSBXaGl0ZWxpc3RlZCBUb2tlbnMgaW4gcGF5bWVudFsxXS4EAAAAIVByZXZpb3VzRnVuZHNBZGRlZFRvUG9vbGJ5Q29tcGFueQQAAAAHJG1hdGNoMAkABBoAAAACBQAAAAR0aGlzAgAAAA5Ub3RhbF9MUF9BZGRlZAMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAADSW50BAAAAAFhBQAAAAckbWF0Y2gwBQAAAAFhAAAAAAAAAAAABAAAACNUb3RhbE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AAAICAAAADlRvdGFsX0xQX0FkZGVkBQAAACNUb3RhbEZ1bmRzRnVuZHNBZGRlZFRvUG9vbGJ5Q29tcGFueQUAAAADbmlsAAAAAQAAAAJ0eAEAAAAGdmVyaWZ5AAAAAAQAAAAHJG1hdGNoMAUAAAACdHgDAwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAAVPcmRlcgYDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAE0V4Y2hhbmdlVHJhbnNhY3Rpb24GCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAE1RyYW5zZmVyVHJhbnNhY3Rpb24EAAAAAXQFAAAAByRtYXRjaDAHCQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAAgFAAAAAnR4AAAAD3NlbmRlclB1YmxpY0tledMwjPU=", "height": 2727377, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: none Next: FzMW8RBaeRjCPu83mJspDApgzkqLKMNzZbs8DxzudBFf Full:
Old | New | Differences | |
---|---|---|---|
1 | - | # no script | |
1 | + | {-# STDLIB_VERSION 5 #-} | |
2 | + | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | + | {-# CONTENT_TYPE DAPP #-} | |
4 | + | ||
5 | + | ||
6 | + | @Callable(i) | |
7 | + | func AddPoolLiquidity () = { | |
8 | + | let calleraddress = toBase58String(i.caller.bytes) | |
9 | + | let pmt = if ((size(i.payments) == 1)) | |
10 | + | then i.payments[0] | |
11 | + | else throw("No payment attached, Please Attach only Whitelisted Tokens in payment[1].") | |
12 | + | let PreviousFundsAddedToPoolbyCompany = match getInteger(this, "Total_LP_Added") { | |
13 | + | case a: Int => | |
14 | + | a | |
15 | + | case _ => | |
16 | + | 0 | |
17 | + | } | |
18 | + | let TotalFundsFundsAddedToPoolbyCompany = (PreviousFundsAddedToPoolbyCompany + pmt.amount) | |
19 | + | let PreviousPoolLiquidity = match getInteger(this, "Total_Pool_Liquidity") { | |
20 | + | case a: Int => | |
21 | + | a | |
22 | + | case _ => | |
23 | + | 0 | |
24 | + | } | |
25 | + | let TotalPoolLiquidity = (PreviousPoolLiquidity + pmt.amount) | |
26 | + | let PreviousLPDepositCounter = match getInteger(this, "LP_Deposit_Counter") { | |
27 | + | case a: Int => | |
28 | + | a | |
29 | + | case _ => | |
30 | + | 0 | |
31 | + | } | |
32 | + | let TotalLPDepositCounter = (PreviousLPDepositCounter + 1) | |
33 | + | if (isDefined(pmt.assetId)) | |
34 | + | then throw("Only WAVES is allowed to deposit at the moment") | |
35 | + | else [IntegerEntry("Total_Pool_Liquidity", TotalPoolLiquidity), IntegerEntry("LP_Deposit_Counter", TotalLPDepositCounter), IntegerEntry("Total_LP_Added", TotalFundsFundsAddedToPoolbyCompany)] | |
36 | + | } | |
37 | + | ||
38 | + | ||
39 | + | @Verifier(tx) | |
40 | + | func verify () = match tx { | |
41 | + | case t: Order|ExchangeTransaction|TransferTransaction => | |
42 | + | false | |
43 | + | case _ => | |
44 | + | sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey) | |
45 | + | } | |
46 | + |
github/deemru/w8io/026f985 16.84 ms ◑