tx · 8Wt8G9Y4s7vAsviL4koNi23THBRxGVaCoFQLc7cAHubF 3N61Cvq5XcnPk9rxpy2Rnp3bSr4syNGUJph: -0.01400000 Waves 2022.01.15 13:26 [1879956] smart account 3N61Cvq5XcnPk9rxpy2Rnp3bSr4syNGUJph > SELF 0.00000000 Waves
{ "type": 13, "id": "8Wt8G9Y4s7vAsviL4koNi23THBRxGVaCoFQLc7cAHubF", "fee": 1400000, "feeAssetId": null, "timestamp": 1642242523037, "version": 2, "chainId": 84, "sender": "3N61Cvq5XcnPk9rxpy2Rnp3bSr4syNGUJph", "senderPublicKey": "G7cNXePvAHUHmZfXa1eHnvFeH6DuykPC5wm9v9djTKgD", "proofs": [ "2czujt9RezUoRhpw9aEZMnMsGjuV7jGyUwReHgBT5Yn3By6dTjPRmg6qoYR2ZLyRqgG7uxswRSBpkXVZNi9s9PUk", "5X5so2aGtLPPBEUhrmLMhNF6NbMNAdC8HN6LmButvLj4x7uqyqVRUTYpz7X68DchKPcmF8xGGh9KRmbfR6oVc3cM", "45mNMSYjqAYZy9zmXmejxtTEMZJkEkzJYMD1bTeCn1tJYBoVKnc9RoH3MEm7kW5oRqF1JuKRXiV31VpYXZ9C4HjT" ], "script": "base64:AAIFAAAAAAAAB9IIAhIGCgQYGBgREgMKARgSBgoECAgBARIAEgMKAQgSAwoBCBIECgIYFBoTCgFBEg50cmFuc2ZlclRvVXNlchoLCgFCEgZhbW91bnQaDAoBQxIHYXNzZXRJZBoJCgFEEgR0eXBlGhUKAUUSEGRBcHBTdGFrZWRUb2tlbnMaFAoBRhIPYXNzZXRJZFF1YW50aXR5GgoKAUcSBWFzc2V0GhkKAUgSFHRyYW5zZmVyVG9Vc2VyQW1vdW50GgYKAUkSAWkaCgoBShIFcG9vbHMaFAoBSxIPbGlxdWlkaXR5VG9rZW5zGhIKAUwSDXNlcnZpY2VUb2tlbnMaGwoBTRIWbGlxdWlkaXR5VG9rZW5EZWNpbWFscxoVCgFOEhBnZW5lcmF0ZVBvb2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entComplexity": 0 } View: original | compacted Prev: 9geSeobvSjdTMtjczoKTUS2UWBcNiv6GjXEqDY5HPqq6 Next: 7JGivjj9bn4Snc1ZcCjCHw2xVgVY8vRwf1eHoPqicUd Diff:
Old | New | Differences | |
---|---|---|---|
16 | 16 | let adminPubKey4 = base58'ALsqwPqiUP3bVbM7grozc1Y5oHVBAGKqACRJ5J8RXceC' | |
17 | 17 | ||
18 | 18 | let govermanceAddress = Address(base58'3N7ExjwfofPYTvNBv2zqtAtLcMxqjTxS7iL') | |
19 | + | ||
20 | + | let depositType = "deposit" | |
21 | + | ||
22 | + | let withdrawType = "withdraw" | |
19 | 23 | ||
20 | 24 | let farmingAddress = Address(base58'3NBTuZhn2CwAgWGL99qpGDjZQ4Wtbg56iDL') | |
21 | 25 | ||
61 | 65 | } | |
62 | 66 | ||
63 | 67 | ||
64 | - | func transferToUser (amount,assetId,poolAddress) = { | |
68 | + | func transferToUser (amount,assetId,poolAddress,type) = { | |
65 | 69 | let dAppStakedTokens = getStakedAmount(poolAddress) | |
66 | 70 | let assetIdQuantity = match assetInfo(assetId) { | |
67 | 71 | case asset: Asset => | |
71 | 75 | } | |
72 | 76 | if ((dAppStakedTokens == 0)) | |
73 | 77 | then amount | |
74 | - | else { | |
75 | - | let transferToUserAmount = fraction(amount, assetIdQuantity, dAppStakedTokens) | |
76 | - | transferToUserAmount | |
77 | - | } | |
78 | + | else if ((type == depositType)) | |
79 | + | then { | |
80 | + | let transferToUserAmount = fraction(amount, assetIdQuantity, dAppStakedTokens) | |
81 | + | transferToUserAmount | |
82 | + | } | |
83 | + | else { | |
84 | + | let transferToUserAmount = fraction(amount, dAppStakedTokens, assetIdQuantity) | |
85 | + | transferToUserAmount | |
86 | + | } | |
78 | 87 | } | |
79 | 88 | ||
80 | 89 | ||
260 | 269 | 0 | |
261 | 270 | } | |
262 | 271 | let userAmountWithoutFee = ((amount - fraction(amount, 1, depositFee, HALFUP)) - fraction(amount, 1, controllerFee, HALFUP)) | |
263 | - | let transferToUserAmount = transferToUser(userAmountWithoutFee, fromBase58String(dAppAssetAddress), pool) | |
272 | + | let transferToUserAmount = transferToUser(userAmountWithoutFee, fromBase58String(dAppAssetAddress), pool, depositType) | |
264 | 273 | let fee = (amount - userAmountWithoutFee) | |
265 | 274 | let newPoolAmount = ((poolAmount + amount) - fee) | |
266 | 275 | let newUserPoolAmount = (userAmount + transferToUserAmount) | |
303 | 312 | let liquidutyAssetAddress = getLiquidutyAssetAddress(pool) | |
304 | 313 | let poolAmount = getIntegerValue(this, poolAmountKey) | |
305 | 314 | let userAmountWithoutFee = ((amount - fraction(amount, 1, platformFee, HALFUP)) - fraction(amount, 1, controllerFee, HALFUP)) | |
306 | - | let transferToUserAmount = transferToUser(userAmountWithoutFee, fromBase58String(assetIdString), pool) | |
315 | + | let transferToUserAmount = transferToUser(userAmountWithoutFee, fromBase58String(assetIdString), pool, withdrawType) | |
307 | 316 | let newPoolAmount = (poolAmount - userAmountWithoutFee) | |
308 | 317 | let fee = (amount - userAmountWithoutFee) | |
309 | 318 | let newUserPoolAmount = (userAmount - amount) |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let depositFee = 1000 | |
5 | 5 | ||
6 | 6 | let controllerFee = 10000 | |
7 | 7 | ||
8 | 8 | let platformFee = 10000 | |
9 | 9 | ||
10 | 10 | let adminPubKey1 = base58'68Po1k24uP6goKr7RDmXPg4QkMiKuyTMEirao14rif8s' | |
11 | 11 | ||
12 | 12 | let adminPubKey2 = base58'Bze4aurT9WmLgBT6swA9CajaZFtUwhtwCri6XGAjnAkt' | |
13 | 13 | ||
14 | 14 | let adminPubKey3 = base58'ALsqwPqiUP3bVbM7grozc1Y5oHVBAGKqACRJ5J8RXceC' | |
15 | 15 | ||
16 | 16 | let adminPubKey4 = base58'ALsqwPqiUP3bVbM7grozc1Y5oHVBAGKqACRJ5J8RXceC' | |
17 | 17 | ||
18 | 18 | let govermanceAddress = Address(base58'3N7ExjwfofPYTvNBv2zqtAtLcMxqjTxS7iL') | |
19 | + | ||
20 | + | let depositType = "deposit" | |
21 | + | ||
22 | + | let withdrawType = "withdraw" | |
19 | 23 | ||
20 | 24 | let farmingAddress = Address(base58'3NBTuZhn2CwAgWGL99qpGDjZQ4Wtbg56iDL') | |
21 | 25 | ||
22 | 26 | let swopFiPools = ["3PPH7x7iqobW5ziyiRCic19rQqKr6nPYaK1", "3PKy2mZqnvT2EtpwDim9Mgs6YvCRe4s85nX", "3P27S9V36kw2McjWRZ37AxTx8iwkd7HXw6W"] | |
23 | 27 | ||
24 | 28 | let swopFiFunctions = ["replenishWithTwoTokens", "exchange"] | |
25 | 29 | ||
26 | 30 | func isPoolActive (pool) = { | |
27 | 31 | let kActive = (pool + "_active") | |
28 | 32 | let isActive = match getBoolean(this, kActive) { | |
29 | 33 | case boolean: Boolean => | |
30 | 34 | boolean | |
31 | 35 | case _ => | |
32 | 36 | throw("Pool is not active!") | |
33 | 37 | } | |
34 | 38 | isActive | |
35 | 39 | } | |
36 | 40 | ||
37 | 41 | ||
38 | 42 | func getDAppAssetAddress (pool) = match getString((pool + "_service_token")) { | |
39 | 43 | case string: String => | |
40 | 44 | string | |
41 | 45 | case nothing => | |
42 | 46 | throw("You try to deposit on unsupported pool") | |
43 | 47 | } | |
44 | 48 | ||
45 | 49 | ||
46 | 50 | func getLiquidutyAssetAddress (pool) = match getString((pool + "_liquidity_token")) { | |
47 | 51 | case string: String => | |
48 | 52 | string | |
49 | 53 | case nothing => | |
50 | 54 | throw("You try to withdraw from unsupported pool") | |
51 | 55 | } | |
52 | 56 | ||
53 | 57 | ||
54 | 58 | func getStakedAmount (poolAddress) = match getInteger(farmingAddress, (((poolAddress + "_") + toString(this)) + "_share_tokens_locked")) { | |
55 | 59 | case staked: Int => | |
56 | 60 | staked | |
57 | 61 | case nothing: Unit => | |
58 | 62 | 0 | |
59 | 63 | case _ => | |
60 | 64 | throw("Match error") | |
61 | 65 | } | |
62 | 66 | ||
63 | 67 | ||
64 | - | func transferToUser (amount,assetId,poolAddress) = { | |
68 | + | func transferToUser (amount,assetId,poolAddress,type) = { | |
65 | 69 | let dAppStakedTokens = getStakedAmount(poolAddress) | |
66 | 70 | let assetIdQuantity = match assetInfo(assetId) { | |
67 | 71 | case asset: Asset => | |
68 | 72 | asset.quantity | |
69 | 73 | case _ => | |
70 | 74 | throw("Can't find asset") | |
71 | 75 | } | |
72 | 76 | if ((dAppStakedTokens == 0)) | |
73 | 77 | then amount | |
74 | - | else { | |
75 | - | let transferToUserAmount = fraction(amount, assetIdQuantity, dAppStakedTokens) | |
76 | - | transferToUserAmount | |
77 | - | } | |
78 | + | else if ((type == depositType)) | |
79 | + | then { | |
80 | + | let transferToUserAmount = fraction(amount, assetIdQuantity, dAppStakedTokens) | |
81 | + | transferToUserAmount | |
82 | + | } | |
83 | + | else { | |
84 | + | let transferToUserAmount = fraction(amount, dAppStakedTokens, assetIdQuantity) | |
85 | + | transferToUserAmount | |
86 | + | } | |
78 | 87 | } | |
79 | 88 | ||
80 | 89 | ||
81 | 90 | @Callable(i) | |
82 | 91 | func addPools (pools,liquidityTokens,serviceTokens,liquidityTokenDecimals) = if (containsElement([adminPubKey1, adminPubKey2, adminPubKey3], i.callerPublicKey)) | |
83 | 92 | then { | |
84 | 93 | func generatePoolKeys (accumulated,pool) = IntegerEntry((pool + "_asset_balance"), 0) :: accumulated | |
85 | 94 | ||
86 | 95 | func generatePoolLiquidityTokenKeys (accumulated,pool) = { | |
87 | 96 | let poolIndex = value(indexOf(pools, pool)) | |
88 | 97 | let liquidityToken = liquidityTokens[poolIndex] | |
89 | 98 | StringEntry((pool + "_liquidity_token"), liquidityToken) :: accumulated | |
90 | 99 | } | |
91 | 100 | ||
92 | 101 | func generatePoolServiceTokenKeys (accumulated,pool) = { | |
93 | 102 | let poolIndex = value(indexOf(pools, pool)) | |
94 | 103 | let liquidityToken = serviceTokens[poolIndex] | |
95 | 104 | StringEntry((pool + "_service_token"), liquidityToken) :: accumulated | |
96 | 105 | } | |
97 | 106 | ||
98 | 107 | func generatePoolLiquidityTokenDecimalKeys (accumulated,pool) = { | |
99 | 108 | let poolIndex = value(indexOf(pools, pool)) | |
100 | 109 | let liquidityToken = liquidityTokenDecimals[poolIndex] | |
101 | 110 | IntegerEntry((pool + "_service_token_decimal"), liquidityToken) :: accumulated | |
102 | 111 | } | |
103 | 112 | ||
104 | 113 | func generatePoolActiveKeys (accumulated,pool) = BooleanEntry((pool + "_active"), true) :: accumulated | |
105 | 114 | ||
106 | 115 | let poolBalanceKeys = { | |
107 | 116 | let $l = pools | |
108 | 117 | let $s = size($l) | |
109 | 118 | let $acc0 = nil | |
110 | 119 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
111 | 120 | then $a | |
112 | 121 | else generatePoolKeys($a, $l[$i]) | |
113 | 122 | ||
114 | 123 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
115 | 124 | then $a | |
116 | 125 | else throw("List size exceeds 20") | |
117 | 126 | ||
118 | 127 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20) | |
119 | 128 | } | |
120 | 129 | let poolLiquidityTokenKeys = { | |
121 | 130 | let $l = pools | |
122 | 131 | let $s = size($l) | |
123 | 132 | let $acc0 = nil | |
124 | 133 | func $f1_1 ($a,$i) = if (($i >= $s)) | |
125 | 134 | then $a | |
126 | 135 | else generatePoolLiquidityTokenKeys($a, $l[$i]) | |
127 | 136 | ||
128 | 137 | func $f1_2 ($a,$i) = if (($i >= $s)) | |
129 | 138 | then $a | |
130 | 139 | else throw("List size exceeds 20") | |
131 | 140 | ||
132 | 141 | $f1_2($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($f1_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20) | |
133 | 142 | } | |
134 | 143 | let poolServiceTokenKeys = { | |
135 | 144 | let $l = pools | |
136 | 145 | let $s = size($l) | |
137 | 146 | let $acc0 = nil | |
138 | 147 | func $f2_1 ($a,$i) = if (($i >= $s)) | |
139 | 148 | then $a | |
140 | 149 | else generatePoolServiceTokenKeys($a, $l[$i]) | |
141 | 150 | ||
142 | 151 | func $f2_2 ($a,$i) = if (($i >= $s)) | |
143 | 152 | then $a | |
144 | 153 | else throw("List size exceeds 20") | |
145 | 154 | ||
146 | 155 | $f2_2($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($f2_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20) | |
147 | 156 | } | |
148 | 157 | let poolLiquidityTokenDecimalKeys = { | |
149 | 158 | let $l = pools | |
150 | 159 | let $s = size($l) | |
151 | 160 | let $acc0 = nil | |
152 | 161 | func $f3_1 ($a,$i) = if (($i >= $s)) | |
153 | 162 | then $a | |
154 | 163 | else generatePoolLiquidityTokenDecimalKeys($a, $l[$i]) | |
155 | 164 | ||
156 | 165 | func $f3_2 ($a,$i) = if (($i >= $s)) | |
157 | 166 | then $a | |
158 | 167 | else throw("List size exceeds 20") | |
159 | 168 | ||
160 | 169 | $f3_2($f3_1($f3_1($f3_1($f3_1($f3_1($f3_1($f3_1($f3_1($f3_1($f3_1($f3_1($f3_1($f3_1($f3_1($f3_1($f3_1($f3_1($f3_1($f3_1($f3_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20) | |
161 | 170 | } | |
162 | 171 | let poolActiveKeys = { | |
163 | 172 | let $l = pools | |
164 | 173 | let $s = size($l) | |
165 | 174 | let $acc0 = nil | |
166 | 175 | func $f4_1 ($a,$i) = if (($i >= $s)) | |
167 | 176 | then $a | |
168 | 177 | else generatePoolActiveKeys($a, $l[$i]) | |
169 | 178 | ||
170 | 179 | func $f4_2 ($a,$i) = if (($i >= $s)) | |
171 | 180 | then $a | |
172 | 181 | else throw("List size exceeds 20") | |
173 | 182 | ||
174 | 183 | $f4_2($f4_1($f4_1($f4_1($f4_1($f4_1($f4_1($f4_1($f4_1($f4_1($f4_1($f4_1($f4_1($f4_1($f4_1($f4_1($f4_1($f4_1($f4_1($f4_1($f4_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20) | |
175 | 184 | } | |
176 | 185 | ((((poolBalanceKeys ++ poolLiquidityTokenKeys) ++ poolServiceTokenKeys) ++ poolLiquidityTokenDecimalKeys) ++ poolActiveKeys) | |
177 | 186 | } | |
178 | 187 | else throw("Only admin can call this function") | |
179 | 188 | ||
180 | 189 | ||
181 | 190 | ||
182 | 191 | @Callable(i) | |
183 | 192 | func deleteDepositLockRecords (records) = if (containsElement([adminPubKey1, adminPubKey2, adminPubKey3], i.callerPublicKey)) | |
184 | 193 | then { | |
185 | 194 | func generateDeletingKeys (accumulated,record) = DeleteEntry((record + "_locked")) :: accumulated | |
186 | 195 | ||
187 | 196 | let deleteKeys = { | |
188 | 197 | let $l = records | |
189 | 198 | let $s = size($l) | |
190 | 199 | let $acc0 = nil | |
191 | 200 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
192 | 201 | then $a | |
193 | 202 | else generateDeletingKeys($a, $l[$i]) | |
194 | 203 | ||
195 | 204 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
196 | 205 | then $a | |
197 | 206 | else throw("List size exceeds 100") | |
198 | 207 | ||
199 | 208 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56), 57), 58), 59), 60), 61), 62), 63), 64), 65), 66), 67), 68), 69), 70), 71), 72), 73), 74), 75), 76), 77), 78), 79), 80), 81), 82), 83), 84), 85), 86), 87), 88), 89), 90), 91), 92), 93), 94), 95), 96), 97), 98), 99), 100) | |
200 | 209 | } | |
201 | 210 | deleteKeys | |
202 | 211 | } | |
203 | 212 | else throw("Only admin can call this function") | |
204 | 213 | ||
205 | 214 | ||
206 | 215 | ||
207 | 216 | @Callable(i) | |
208 | 217 | func issueToken (name,description,quantity,decimals) = if (containsElement([adminPubKey1, adminPubKey2, adminPubKey3], i.callerPublicKey)) | |
209 | 218 | then [Issue(name, description, quantity, decimals, true, unit, 0)] | |
210 | 219 | else throw("Only admin can call this function") | |
211 | 220 | ||
212 | 221 | ||
213 | 222 | ||
214 | 223 | @Callable(a8) | |
215 | 224 | func call () = [DeleteEntry("3PPH7x7iqobW5ziyiRCic19rQqKr6nPYaK1_3N5viYFhnu1ew4FRZ9nujme9edr918FkT1a_current_reward")] | |
216 | 225 | ||
217 | 226 | ||
218 | 227 | ||
219 | 228 | @Callable(i) | |
220 | 229 | func deposit (pool) = if ((size(i.payments) != 1)) | |
221 | 230 | then throw("One attached payment expected") | |
222 | 231 | else { | |
223 | 232 | let amount = i.payments[0].amount | |
224 | 233 | let assetId = i.payments[0].assetId | |
225 | 234 | let assetIdString = match assetId { | |
226 | 235 | case id: ByteVector => | |
227 | 236 | toBase58String(id) | |
228 | 237 | case _ => | |
229 | 238 | throw("Match error") | |
230 | 239 | } | |
231 | 240 | if ((0 >= amount)) | |
232 | 241 | then throw(("Deposit amount must be positive. Actual: " + toString(amount))) | |
233 | 242 | else { | |
234 | 243 | let poolAmountKey = (pool + "_asset_balance") | |
235 | 244 | let userAddress = toString(i.caller) | |
236 | 245 | let userPoolAmountKey = (((pool + "_") + userAddress) + "_asset_balance") | |
237 | 246 | let dAppAssetAddress = getDAppAssetAddress(pool) | |
238 | 247 | let liquidutyAssetAddress = match getString((pool + "_liquidity_token")) { | |
239 | 248 | case string: String => | |
240 | 249 | string | |
241 | 250 | case nothing => | |
242 | 251 | throw("You try to deposit on unsupported pool") | |
243 | 252 | } | |
244 | 253 | if (isPoolActive(pool)) | |
245 | 254 | then { | |
246 | 255 | let liquidityTokenDecimal = match assetInfo(fromBase58String(liquidutyAssetAddress)) { | |
247 | 256 | case asset: Asset => | |
248 | 257 | asset.decimals | |
249 | 258 | case _ => | |
250 | 259 | throw("Can't find asset") | |
251 | 260 | } | |
252 | 261 | if ((liquidutyAssetAddress != assetIdString)) | |
253 | 262 | then throw("You attached wrong liquidity token from Swop.fi") | |
254 | 263 | else { | |
255 | 264 | let poolAmount = getIntegerValue(this, poolAmountKey) | |
256 | 265 | let userAmount = match getInteger(userPoolAmountKey) { | |
257 | 266 | case int: Int => | |
258 | 267 | int | |
259 | 268 | case nothing => | |
260 | 269 | 0 | |
261 | 270 | } | |
262 | 271 | let userAmountWithoutFee = ((amount - fraction(amount, 1, depositFee, HALFUP)) - fraction(amount, 1, controllerFee, HALFUP)) | |
263 | - | let transferToUserAmount = transferToUser(userAmountWithoutFee, fromBase58String(dAppAssetAddress), pool) | |
272 | + | let transferToUserAmount = transferToUser(userAmountWithoutFee, fromBase58String(dAppAssetAddress), pool, depositType) | |
264 | 273 | let fee = (amount - userAmountWithoutFee) | |
265 | 274 | let newPoolAmount = ((poolAmount + amount) - fee) | |
266 | 275 | let newUserPoolAmount = (userAmount + transferToUserAmount) | |
267 | 276 | let lockTokensKey = (((((pool + "_") + userAddress) + "_") + toBase58String(i.transactionId)) + "_locked") | |
268 | 277 | [Reissue(fromBase58String(dAppAssetAddress), transferToUserAmount, true), ScriptTransfer(i.caller, transferToUserAmount, fromBase58String(dAppAssetAddress)), ScriptTransfer(govermanceAddress, fee, fromBase58String(liquidutyAssetAddress)), IntegerEntry(lockTokensKey, userAmountWithoutFee), IntegerEntry(poolAmountKey, newPoolAmount), IntegerEntry(userPoolAmountKey, newUserPoolAmount)] | |
269 | 278 | } | |
270 | 279 | } | |
271 | 280 | else throw("Pool is not active!") | |
272 | 281 | } | |
273 | 282 | } | |
274 | 283 | ||
275 | 284 | ||
276 | 285 | ||
277 | 286 | @Callable(i) | |
278 | 287 | func withdraw (pool) = if ((size(i.payments) != 1)) | |
279 | 288 | then throw("One attached payment expected") | |
280 | 289 | else { | |
281 | 290 | let amount = i.payments[0].amount | |
282 | 291 | let assetId = i.payments[0].assetId | |
283 | 292 | let assetIdString = match assetId { | |
284 | 293 | case id: ByteVector => | |
285 | 294 | toBase58String(id) | |
286 | 295 | case _ => | |
287 | 296 | throw("Match error") | |
288 | 297 | } | |
289 | 298 | if ((0 >= amount)) | |
290 | 299 | then throw(("Deposit amount must be positive. Actual: " + toString(amount))) | |
291 | 300 | else if (isPoolActive(pool)) | |
292 | 301 | then { | |
293 | 302 | let poolAmountKey = (pool + "_asset_balance") | |
294 | 303 | let userAddress = toString(i.caller) | |
295 | 304 | let userPoolAmountKey = (((pool + "_") + userAddress) + "_asset_balance") | |
296 | 305 | let userAmount = match getInteger(userPoolAmountKey) { | |
297 | 306 | case int: Int => | |
298 | 307 | int | |
299 | 308 | case nothing => | |
300 | 309 | 0 | |
301 | 310 | } | |
302 | 311 | let dAppAssetAddress = getDAppAssetAddress(pool) | |
303 | 312 | let liquidutyAssetAddress = getLiquidutyAssetAddress(pool) | |
304 | 313 | let poolAmount = getIntegerValue(this, poolAmountKey) | |
305 | 314 | let userAmountWithoutFee = ((amount - fraction(amount, 1, platformFee, HALFUP)) - fraction(amount, 1, controllerFee, HALFUP)) | |
306 | - | let transferToUserAmount = transferToUser(userAmountWithoutFee, fromBase58String(assetIdString), pool) | |
315 | + | let transferToUserAmount = transferToUser(userAmountWithoutFee, fromBase58String(assetIdString), pool, withdrawType) | |
307 | 316 | let newPoolAmount = (poolAmount - userAmountWithoutFee) | |
308 | 317 | let fee = (amount - userAmountWithoutFee) | |
309 | 318 | let newUserPoolAmount = (userAmount - amount) | |
310 | 319 | [Burn(fromBase58String(dAppAssetAddress), transferToUserAmount), ScriptTransfer(i.caller, transferToUserAmount, fromBase58String(liquidutyAssetAddress)), ScriptTransfer(govermanceAddress, fee, fromBase58String(liquidutyAssetAddress)), IntegerEntry(poolAmountKey, newPoolAmount), IntegerEntry(userPoolAmountKey, newUserPoolAmount)] | |
311 | 320 | } | |
312 | 321 | else throw("Pool is not active!") | |
313 | 322 | } | |
314 | 323 | ||
315 | 324 | ||
316 | 325 | ||
317 | 326 | @Callable(i) | |
318 | 327 | func poolActivating (pools,statuses) = if (containsElement([adminPubKey1, adminPubKey2, adminPubKey3], i.callerPublicKey)) | |
319 | 328 | then { | |
320 | 329 | func generatePoolActiveKeys (accumulated,pool) = { | |
321 | 330 | let poolIndex = value(indexOf(pools, pool)) | |
322 | 331 | let status = statuses[poolIndex] | |
323 | 332 | BooleanEntry((pool + "_active"), status) :: accumulated | |
324 | 333 | } | |
325 | 334 | ||
326 | 335 | let poolActiveKeys = { | |
327 | 336 | let $l = pools | |
328 | 337 | let $s = size($l) | |
329 | 338 | let $acc0 = nil | |
330 | 339 | func $f0_1 ($a,$i) = if (($i >= $s)) | |
331 | 340 | then $a | |
332 | 341 | else generatePoolActiveKeys($a, $l[$i]) | |
333 | 342 | ||
334 | 343 | func $f0_2 ($a,$i) = if (($i >= $s)) | |
335 | 344 | then $a | |
336 | 345 | else throw("List size exceeds 100") | |
337 | 346 | ||
338 | 347 | $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10), 11), 12), 13), 14), 15), 16), 17), 18), 19), 20), 21), 22), 23), 24), 25), 26), 27), 28), 29), 30), 31), 32), 33), 34), 35), 36), 37), 38), 39), 40), 41), 42), 43), 44), 45), 46), 47), 48), 49), 50), 51), 52), 53), 54), 55), 56), 57), 58), 59), 60), 61), 62), 63), 64), 65), 66), 67), 68), 69), 70), 71), 72), 73), 74), 75), 76), 77), 78), 79), 80), 81), 82), 83), 84), 85), 86), 87), 88), 89), 90), 91), 92), 93), 94), 95), 96), 97), 98), 99), 100) | |
339 | 348 | } | |
340 | 349 | poolActiveKeys | |
341 | 350 | } | |
342 | 351 | else throw("Only admin can call this function") | |
343 | 352 | ||
344 | 353 | ||
345 | 354 | @Verifier(tx) | |
346 | 355 | func verify () = match tx { | |
347 | 356 | case inv: InvokeScriptTransaction => | |
348 | 357 | let lockShareTokens = if ((inv.dApp == farmingAddress)) | |
349 | 358 | then if (if ((inv.function == "lockShareTokens")) | |
350 | 359 | then true | |
351 | 360 | else (inv.function == "claim")) | |
352 | 361 | then true | |
353 | 362 | else (inv.function == "withdrawShareTokens") | |
354 | 363 | else false | |
355 | 364 | let dAppAddress = match inv.dApp { | |
356 | 365 | case dApp: Address => | |
357 | 366 | toString(dApp) | |
358 | 367 | case _ => | |
359 | 368 | throw("Transaction must have only address") | |
360 | 369 | } | |
361 | 370 | let poolFunctions = if (containsElement(swopFiPools, dAppAddress)) | |
362 | 371 | then containsElement(swopFiFunctions, inv.function) | |
363 | 372 | else false | |
364 | 373 | let signedByAdmin = if (if (if (sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey1)) | |
365 | 374 | then true | |
366 | 375 | else sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey2)) | |
367 | 376 | then true | |
368 | 377 | else sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey4)) | |
369 | 378 | then true | |
370 | 379 | else sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey) | |
371 | 380 | if (if (lockShareTokens) | |
372 | 381 | then true | |
373 | 382 | else poolFunctions) | |
374 | 383 | then signedByAdmin | |
375 | 384 | else false | |
376 | 385 | case _ => | |
377 | 386 | let adm1Signed = if (sigVerify(tx.bodyBytes, tx.proofs[0], adminPubKey1)) | |
378 | 387 | then 1 | |
379 | 388 | else 0 | |
380 | 389 | let adm2Signed = if (sigVerify(tx.bodyBytes, tx.proofs[1], adminPubKey2)) | |
381 | 390 | then 1 | |
382 | 391 | else 0 | |
383 | 392 | let adm3Signed = if (sigVerify(tx.bodyBytes, tx.proofs[2], adminPubKey3)) | |
384 | 393 | then 1 | |
385 | 394 | else 0 | |
386 | 395 | (((adm1Signed + adm2Signed) + adm3Signed) >= 2) | |
387 | 396 | } | |
388 | 397 |
github/deemru/w8io/026f985 81.21 ms ◑