tx · AJtyQqfcBfweA2uoLAqTnXu8ZjtgDZothrZugZtC61Bi

3N61Cvq5XcnPk9rxpy2Rnp3bSr4syNGUJph:  -0.01400000 Waves

2021.11.05 17:20 [1777798] smart account 3N61Cvq5XcnPk9rxpy2Rnp3bSr4syNGUJph > SELF 0.00000000 Waves

{ "type": 13, "id": "AJtyQqfcBfweA2uoLAqTnXu8ZjtgDZothrZugZtC61Bi", "fee": 1400000, "feeAssetId": null, "timestamp": 1636122105058, "version": 2, "chainId": 84, "sender": "3N61Cvq5XcnPk9rxpy2Rnp3bSr4syNGUJph", "senderPublicKey": "G7cNXePvAHUHmZfXa1eHnvFeH6DuykPC5wm9v9djTKgD", "proofs": [ "2yHrzsWTrjQy4xCvzq7jv2wSTg1vNQjGEC7ETqyeTfNZuyiMdBgLc3RswgmWrqXPfdybjr7mxCENnn1eVyMHkCpd" ], "script": "base64:AAIFAAAAAAAAABkIAhIAEgYKBBgYGBESABIDCgEIEgQKAggBAAAAAwAAAAAKZGVwb3NpdEZlZQAAAAAAAAAD6AAAAAANY29udHJvbGxlckZlZQAAAAAAAAAnEAAAAAALcGxhdGZvcm1GZWUAAAAAAAAAJxAAAAAFAAAAAmE4AQAAAARpbml0AAAAAAkABEwAAAACCQEAAAAMSW50ZWdlckVudHJ5AAAAAgIAAAAxM1BQSDd4N2lxb2JXNXppeWlSQ2ljMTlyUXFLcjZuUFlhSzFfYXNzZXRfYmFsYW5jZQAAAAAAAG3UrQUAAAADbmlsAAAAAWkBAAAACGFkZFBvb2xzAAAABAAAAAVwb29scwAAAA9saXF1aWRpdHlUb2tlbnMAAAANc2VydmljZVRva2VucwAAABZsaXF1aWRpdHlUb2tlbkRlY2ltYWxzCgEAAAAQZ2VuZXJhdGVQb29sS2V5cwAAAAIAAAALYWNjdW11bGF0ZWQAAAAEcG9vbAkABEwAAAACCQEAAAAMSW50ZWdlckVudHJ5AAAAAgkAASwAAAACBQAAAARwb29sAgAAAA5fYXNzZXRfYmFsYW5jZQAAAA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wAAAACCQEAAAAMSW50ZWdlckVudHJ5AAAAAgUAAAARdXNlclBvb2xBbW91bnRLZXkFAAAAEW5ld1VzZXJQb29sQW1vdW50CQAETAAAAAIJAQAAAAxJbnRlZ2VyRW50cnkAAAACBQAAABF1c2VyUG9vbEVhcm5lZEtleQUAAAAPdXNlckVhcm5lZFRvdGFsBQAAAANuaWwJAAACAAAAAQIAAAAmWW91IGhhdmUgbm90IHN1Y2ggYmFsYW5jZSBmb3Igd2l0aGRyYXcAAAABAAAAAmI2AQAAAAJiNwAAAAAJAAH0AAAAAwgFAAAAAmI2AAAACWJvZHlCeXRlcwkAAZEAAAACCAUAAAACYjYAAAAGcHJvb2ZzAAAAAAAAAAAACAUAAAACYjYAAAAPc2VuZGVyUHVibGljS2V57wdJ/w==", "height": 1777798, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 2GAjtyLj88beJnhyWe4iLjFazENSowTdnEqBa9s5eHJ7 Next: DPGyJwiTZotnCSNMm9YXD9JRSrJxWtSBHymJ2qqBoRiF Diff:
OldNewDifferences
2222 StringEntry((pool + "_liquidity_token"), liquidityToken)
2323 }
2424
25- func generatePoolServiceTokenKeys (accumulated,pool) = throw("DApp is inactive at this moment")
25+ func generatePoolServiceTokenKeys (accumulated,pool) = {
26+ let poolIndex = value(indexOf(pools, pool))
27+ let liquidityToken = serviceTokens[poolIndex]
28+ StringEntry((pool + "_service_token"), liquidityToken)
29+ }
2630
2731 func generatePoolLiquidityTokenDecimalKeys (accumulated,pool) = {
2832 let poolIndex = value(indexOf(pools, pool))
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let depositFee = 1000
55
66 let controllerFee = 10000
77
88 let platformFee = 10000
99
1010 @Callable(a8)
1111 func init () = [IntegerEntry("3PPH7x7iqobW5ziyiRCic19rQqKr6nPYaK1_asset_balance", 7197869)]
1212
1313
1414
1515 @Callable(i)
1616 func addPools (pools,liquidityTokens,serviceTokens,liquidityTokenDecimals) = {
1717 func generatePoolKeys (accumulated,pool) = IntegerEntry((pool + "_asset_balance"), 0) :: accumulated
1818
1919 func generatePoolLiquidityTokenKeys (accumulated,pool) = {
2020 let poolIndex = value(indexOf(pools, pool))
2121 let liquidityToken = liquidityTokens[poolIndex]
2222 StringEntry((pool + "_liquidity_token"), liquidityToken)
2323 }
2424
25- func generatePoolServiceTokenKeys (accumulated,pool) = throw("DApp is inactive at this moment")
25+ func generatePoolServiceTokenKeys (accumulated,pool) = {
26+ let poolIndex = value(indexOf(pools, pool))
27+ let liquidityToken = serviceTokens[poolIndex]
28+ StringEntry((pool + "_service_token"), liquidityToken)
29+ }
2630
2731 func generatePoolLiquidityTokenDecimalKeys (accumulated,pool) = {
2832 let poolIndex = value(indexOf(pools, pool))
2933 let liquidityToken = liquidityTokenDecimals[poolIndex]
3034 IntegerEntry((pool + "_service_token"), liquidityToken)
3135 }
3236
3337 func generatePoolActiveKeys (accumulated,pool) = BooleanEntry((pool + "_active"), true)
3438
3539 let poolLiquidityTokenKeys = {
3640 let $l = pools
3741 let $s = size($l)
3842 let $acc0 = nil
3943 func 1 ($a,$i) = if (($i >= $s))
4044 then $a
4145 else generatePoolLiquidityTokenKeys($a, $l[$i])
4246
4347 func 2 ($a,$i) = if (($i >= $s))
4448 then $a
4549 else throw("List size exceeds 20")
4650
4751 2(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20)
4852 }
4953 let poolServiceTokenKeys = {
5054 let $l = pools
5155 let $s = size($l)
5256 let $acc0 = nil
5357 func 1 ($a,$i) = if (($i >= $s))
5458 then $a
5559 else generatePoolServiceTokenKeys($a, $l[$i])
5660
5761 func 2 ($a,$i) = if (($i >= $s))
5862 then $a
5963 else throw("List size exceeds 20")
6064
6165 2(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20)
6266 }
6367 let poolLiquidityTokenDecimalKeys = {
6468 let $l = pools
6569 let $s = size($l)
6670 let $acc0 = nil
6771 func 1 ($a,$i) = if (($i >= $s))
6872 then $a
6973 else generatePoolLiquidityTokenDecimalKeys($a, $l[$i])
7074
7175 func 2 ($a,$i) = if (($i >= $s))
7276 then $a
7377 else throw("List size exceeds 20")
7478
7579 2(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20)
7680 }
7781 let poolActiveKeys = {
7882 let $l = pools
7983 let $s = size($l)
8084 let $acc0 = nil
8185 func 1 ($a,$i) = if (($i >= $s))
8286 then $a
8387 else generatePoolActiveKeys($a, $l[$i])
8488
8589 func 2 ($a,$i) = if (($i >= $s))
8690 then $a
8791 else throw("List size exceeds 20")
8892
8993 2(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1(1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20)
9094 }
9195 poolServiceTokenKeys
9296 }
9397
9498
9599
96100 @Callable(a8)
97101 func call () = {
98102 let a9 = Issue("Asset1", "Asset from dApp", 100000, 2, true, unit, 0)
99103 let b1 = calculateAssetId(a9)
100104 [BinaryEntry("bin", base58''), BooleanEntry("bool", true), IntegerEntry("int", 1), StringEntry("str", ""), DeleteEntry("str"), a9]
101105 }
102106
103107
104108
105109 @Callable(i)
106110 func deposit (pool) = {
107111 let amount = i.payments[0].amount
108112 let assetId = i.payments[0].assetId
109113 let poolAmountKey = (pool + "_asset_balance")
110114 let userAddress = toString(i.caller)
111115 let userPoolAmountKey = (((pool + "_") + userAddress) + "_asset_balance")
112116 let dAppAssetAddress = getStringValue(this, (pool + "_service_token"))
113117 let poolAmount = getIntegerValue(this, poolAmountKey)
114118 let userAmount = match getInteger(userPoolAmountKey) {
115119 case int: Int =>
116120 int
117121 case nothing =>
118122 0
119123 }
120124 let newPoolAmount = (poolAmount + amount)
121125 let userAmountWithoutFee = ((amount - fraction(amount, 1, depositFee, HALFUP)) - fraction(amount, 1, controllerFee, HALFUP))
122126 let newUserPoolAmount = (userAmount + userAmountWithoutFee)
123127 [Reissue(fromBase58String(dAppAssetAddress), userAmountWithoutFee, true), ScriptTransfer(i.caller, userAmountWithoutFee, fromBase58String(dAppAssetAddress)), IntegerEntry(poolAmountKey, newPoolAmount), IntegerEntry(userPoolAmountKey, newUserPoolAmount)]
124128 }
125129
126130
127131
128132 @Callable(i)
129133 func withdraw (pool,userEarned) = {
130134 let amount = i.payments[0].amount
131135 let assetId = i.payments[0].assetId
132136 let poolAmountKey = (pool + "_asset_balance")
133137 let userAddress = toString(i.caller)
134138 let userPoolAmountKey = (((pool + "_") + userAddress) + "_asset_balance")
135139 let userPoolEarnedKey = (((pool + "_") + userAddress) + "_earned")
136140 let poolAmount = getIntegerValue(this, poolAmountKey)
137141 let userAmount = match getInteger(userPoolAmountKey) {
138142 case int: Int =>
139143 int
140144 case nothing =>
141145 0
142146 }
143147 let userEarnedBefore = match getInteger(userPoolEarnedKey) {
144148 case int: Int =>
145149 int
146150 case nothing =>
147151 0
148152 }
149153 let liquidutyAssetAddress = getStringValue(this, (pool + "_liquidity_token"))
150154 let liquidityTokenDecimal = match assetInfo(fromBase58String(liquidutyAssetAddress)) {
151155 case asset: Asset =>
152156 asset.decimals
153157 case _ =>
154158 throw("Can't find asset")
155159 }
156160 let dAppAssetAddress = getStringValue(this, (pool + "_service_token"))
157161 let userEarnedTotal = (userEarned + userEarnedBefore)
158162 let amountWithoutFee = ((amount - fraction(amount, 1, platformFee, HALFUP)) - fraction(amount, 1, controllerFee, HALFUP))
159163 let newPoolAmount = (poolAmount - amountWithoutFee)
160164 if ((userAmount >= amount))
161165 then {
162166 let newUserPoolAmount = (userAmount - amountWithoutFee)
163167 [Burn(fromBase58String(dAppAssetAddress), amountWithoutFee), ScriptTransfer(i.caller, amountWithoutFee, fromBase58String(liquidutyAssetAddress)), IntegerEntry(poolAmountKey, newPoolAmount), IntegerEntry(userPoolAmountKey, newUserPoolAmount), IntegerEntry(userPoolEarnedKey, userEarnedTotal)]
164168 }
165169 else throw("You have not such balance for withdraw")
166170 }
167171
168172
169173 @Verifier(b6)
170174 func b7 () = sigVerify(b6.bodyBytes, b6.proofs[0], b6.senderPublicKey)
171175

github/deemru/w8io/026f985 
35.05 ms