tx · ENEhhdZUpyu5AVBNzMY9L3KbT1MWSJzgfiGRQTGWq88e

3Mx8raFsQfjh2JBeT8MN1Jv5sTvGkx5PDDS:  -0.02000000 Waves

2023.08.27 08:47 [2728673] smart account 3Mx8raFsQfjh2JBeT8MN1Jv5sTvGkx5PDDS > SELF 0.00000000 Waves

{ "type": 13, "id": "ENEhhdZUpyu5AVBNzMY9L3KbT1MWSJzgfiGRQTGWq88e", "fee": 2000000, "feeAssetId": null, "timestamp": 1693115300722, "version": 2, "chainId": 84, "sender": "3Mx8raFsQfjh2JBeT8MN1Jv5sTvGkx5PDDS", "senderPublicKey": "HmWR8GbhBF4LAodJ9xNgR7PpWF79RuCrhPWJWxqdB1KL", "proofs": [ "3oK8UuPQXTXg4ZYdb5YLVtwHWbsLBFqXbm6jiBipyK9tY8n2XGg1fXBBG4f62AFB7D9sGeDJX999smLKVozs1PHE" ], "script": "base64:AAIFAAAAAAAAAAkIAhIAEgMKAQEAAAACAAAAABFscF9hZGRyZXNzX3B1YmtleQEAAAAg+SHOoR+6ay5qXj57vjRzml+/6VMYqCQMV4ukn2GjgTcAAAAAEXdoaXRlbGlzdF9hZGRyZXNzCQEAAAAUYWRkcmVzc0Zyb21QdWJsaWNLZXkAAAABBQAAABFscF9hZGRyZXNzX3B1YmtleQAAAAIAAAABaQEAAAAQQWRkUG9vbExpcXVpZGl0eQAAAAAEAAAADWNhbGxlcmFkZHJlc3MJAAJYAAAAAQgIBQAAAAFpAAAABmNhbGxlcgAAAAVieXRlcwQAAAADcG10AwkAAAAAAAACCQABkAAAAAEIBQAAAAFpAAAACHBheW1lbnRzAAAAAAAAAAABCQABkQAAAAIIBQAAAAFpAAAACHBheW1lbnRzAAAAAAAAAAAACQAAAgAAAAECAAAASU5vIHBheW1lbnQgYXR0YWNoZWQsIFBsZWFzZSBBdHRhY2ggb25seSBXaGl0ZWxpc3RlZCBUb2tlbnMgaW4gcGF5bWVudFsxXS4EAAAAIVByZXZpb3VzRnVuZHNBZGRlZF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U2VuZAUAAAAWUGFpZE1hc3NUcmFuc2ZlckFtb3VudAUAAAADbmlsAAAAAQAAAAJ0eAEAAAAGdmVyaWZ5AAAAAAQAAAAHJG1hdGNoMAUAAAACdHgDAwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAAVPcmRlcgYDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAE0V4Y2hhbmdlVHJhbnNhY3Rpb24GCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAE1RyYW5zZmVyVHJhbnNhY3Rpb24EAAAAAXQFAAAAByRtYXRjaDAHCQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAAgFAAAAAnR4AAAAD3NlbmRlclB1YmxpY0tleb2JA+I=", "height": 2728673, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: FzMW8RBaeRjCPu83mJspDApgzkqLKMNzZbs8DxzudBFf Next: DQXGBkeZ6AAPVNei6XKABde14saaAGJ3Tz55YxsWw4LT Diff:
OldNewDifferences
3232 0
3333 }
3434 let TotalLPDepositCounter = (PreviousLPDepositCounter + 1)
35- if (isDefined(pmt.assetId))
36- then throw("Only WAVES is allowed to deposit at the moment")
37- else [IntegerEntry("Total_Pool_Liquidity", TotalPoolLiquidity), IntegerEntry("LP_Deposit_Counter", TotalLPDepositCounter), IntegerEntry("Total_LP_Added", TotalFundsAddedToPoolbyCompany)]
35+ if ((i.caller != whitelist_address))
36+ then throw((("This Address is not Authorized. Only " + toString(whitelist_address)) + " is Authorized Address to Sign it."))
37+ else if (isDefined(pmt.assetId))
38+ then throw("Only WAVES is allowed to deposit at the moment")
39+ else [IntegerEntry("Total_Pool_Liquidity", TotalPoolLiquidity), IntegerEntry("LP_Deposit_Counter", TotalLPDepositCounter), IntegerEntry("Total_LP_Added", TotalFundsAddedToPoolbyCompany)]
3840 }
3941
4042
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let lp_address_pubkey = base58'HmWR8GbhBF4LAodJ9xNgR7PpWF79RuCrhPWJWxqdB1KL'
55
66 let whitelist_address = addressFromPublicKey(lp_address_pubkey)
77
88 @Callable(i)
99 func AddPoolLiquidity () = {
1010 let calleraddress = toBase58String(i.caller.bytes)
1111 let pmt = if ((size(i.payments) == 1))
1212 then i.payments[0]
1313 else throw("No payment attached, Please Attach only Whitelisted Tokens in payment[1].")
1414 let PreviousFundsAddedToPoolbyCompany = match getInteger(this, "Total_LP_Added") {
1515 case a: Int =>
1616 a
1717 case _ =>
1818 0
1919 }
2020 let TotalFundsAddedToPoolbyCompany = (PreviousFundsAddedToPoolbyCompany + pmt.amount)
2121 let PreviousPoolLiquidity = match getInteger(this, "Total_Pool_Liquidity") {
2222 case a: Int =>
2323 a
2424 case _ =>
2525 0
2626 }
2727 let TotalPoolLiquidity = (PreviousPoolLiquidity + pmt.amount)
2828 let PreviousLPDepositCounter = match getInteger(this, "LP_Deposit_Counter") {
2929 case a: Int =>
3030 a
3131 case _ =>
3232 0
3333 }
3434 let TotalLPDepositCounter = (PreviousLPDepositCounter + 1)
35- if (isDefined(pmt.assetId))
36- then throw("Only WAVES is allowed to deposit at the moment")
37- else [IntegerEntry("Total_Pool_Liquidity", TotalPoolLiquidity), IntegerEntry("LP_Deposit_Counter", TotalLPDepositCounter), IntegerEntry("Total_LP_Added", TotalFundsAddedToPoolbyCompany)]
35+ if ((i.caller != whitelist_address))
36+ then throw((("This Address is not Authorized. Only " + toString(whitelist_address)) + " is Authorized Address to Sign it."))
37+ else if (isDefined(pmt.assetId))
38+ then throw("Only WAVES is allowed to deposit at the moment")
39+ else [IntegerEntry("Total_Pool_Liquidity", TotalPoolLiquidity), IntegerEntry("LP_Deposit_Counter", TotalLPDepositCounter), IntegerEntry("Total_LP_Added", TotalFundsAddedToPoolbyCompany)]
3840 }
3941
4042
4143
4244 @Callable(i)
4345 func UpdateLPBalance (PaidMassTransferAmount) = {
4446 let read_total_pool_liquidity = valueOrErrorMessage(getInteger(this, "Total_Pool_Liquidity"), "No Initial Pool Liquidity was Found.")
4547 let updated_pool_balance = (read_total_pool_liquidity - PaidMassTransferAmount)
4648 let PreviousMassTransferCounter = match getInteger(this, "Mass_Transfer_Counter") {
4749 case a: Int =>
4850 a
4951 case _ =>
5052 0
5153 }
5254 let TotalMassTransferCounter = (PreviousMassTransferCounter + 1)
5355 let PreviousMassTransferSend = match getInteger(this, "Total_Mass_Transfer_Send") {
5456 case a: Int =>
5557 a
5658 case _ =>
5759 0
5860 }
5961 let TotalMassTransferSend = (PreviousMassTransferSend + PaidMassTransferAmount)
6062 if ((i.caller != whitelist_address))
6163 then throw((("This Address is not Authorized. Only " + toString(whitelist_address)) + " is Authorized Address to Sign it."))
6264 else [IntegerEntry("Total_Pool_Liquidity", updated_pool_balance), IntegerEntry("Total_Mass_Transfer_Send", TotalMassTransferSend), IntegerEntry((toString(TotalMassTransferCounter) + "_Mass_Transfer_Send"), PaidMassTransferAmount)]
6365 }
6466
6567
6668 @Verifier(tx)
6769 func verify () = match tx {
6870 case t: Order|ExchangeTransaction|TransferTransaction =>
6971 false
7072 case _ =>
7173 sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
7274 }
7375

github/deemru/w8io/026f985 
28.63 ms