tx · DymBmzh2M1L5H9jT1HDagRBfP92KBRLJtd4hujZ6JwnK 3N61Cvq5XcnPk9rxpy2Rnp3bSr4syNGUJph: -0.01400000 Waves 2021.11.07 21:46 [1780970] smart account 3N61Cvq5XcnPk9rxpy2Rnp3bSr4syNGUJph > SELF 0.00000000 Waves
{ "type": 13, "id": "DymBmzh2M1L5H9jT1HDagRBfP92KBRLJtd4hujZ6JwnK", "fee": 1400000, "feeAssetId": null, "timestamp": 1636310831156, "version": 2, "chainId": 84, "sender": "3N61Cvq5XcnPk9rxpy2Rnp3bSr4syNGUJph", "senderPublicKey": "G7cNXePvAHUHmZfXa1eHnvFeH6DuykPC5wm9v9djTKgD", "proofs": [ "39RYmG36qvYxgiDCoBX4SUDHaSvz3yUq1aWRiAmQj8yZfZ4Ket6QuagJGrro7FjRKo5mvKXjKtQi7bKALXXH6e8o" ], "script": "base64:AAIFAAAAAAAAACEIAhIAEgYKBBgYGBESBgoECAgBARIAEgMKAQgSBAoCCAEAAAAGAAAAAApkZXBvc2l0RmVlAAAAAAAAAAPoAAAAAA1jb250cm9sbGVyRmVlAAAAAAAAACcQAAAAAAtwbGF0Zm9ybUZlZQAAAAAAAAAnEAAAAAAMYWRtaW5QdWJLZXkxAQAAACDvKr/fUaQ4hMSae4iyf4kFpz6rnnDsFuW6KC6s3wMfQQAAAAAMYWRtaW5QdWJLZXkyAQAAACDgkMh3M2mpU305XK7y5b9J+9C9m7ycRhB7Y2h8D+QzGgAAAAAMYWRtaW5QdWJLZXkzAQAAACDgkMh3M2mpU305XK7y5b9J+9C9m7ycRhB7Y2h8D+QzGgAAAAYAAAACYTgBAAAABGluaXQAAAAACQAETAAAAAIJAQAAAAxJbnRlZ2VyRW50cnkAAAACAgAAADEzUFBIN3g3aXFvYlc1eml5aVJDaWMxOXJRcUtyNm5QWWFLMV9hc3NldF9iYWxhbmNlAAAAAAAAbdStBQAAAANuaWwAAAABaQEAAAAIYWRkUG9vbHMAAAAEAAAABXBvb2xzAAAAD2x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NgAAAA9zZW5kZXJQdWJsaWNLZXmt6kvY", "height": 1780970, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 3TcKfYhbq3uMgf8NuW71biaCCZ56uzE5ZH6gSQ3q2zoK Next: 8SmbJrz5LnovNbwHYWWhYqYoD7xpbueH2vg83GHXRsS1 Diff:
Old | New | Differences | |
---|---|---|---|
6 | 6 | let controllerFee = 10000 | |
7 | 7 | ||
8 | 8 | let platformFee = 10000 | |
9 | + | ||
10 | + | let adminPubKey1 = base58'H6cFN4f92Tqmvpuuvii5LhcBHugkttZ7QNJ3tmqYLzuE' | |
11 | + | ||
12 | + | let adminPubKey2 = base58'G7cNXePvAHUHmZfXa1eHnvFeH6DuykPC5wm9v9djTKgD' | |
13 | + | ||
14 | + | let adminPubKey3 = base58'G7cNXePvAHUHmZfXa1eHnvFeH6DuykPC5wm9v9djTKgD' | |
9 | 15 | ||
10 | 16 | @Callable(a8) | |
11 | 17 | func init () = [IntegerEntry("3PPH7x7iqobW5ziyiRCic19rQqKr6nPYaK1_asset_balance", 7197869)] | |
111 | 117 | ||
112 | 118 | ||
113 | 119 | ||
120 | + | @Callable(i) | |
121 | + | func issueToken (name,description,quantity,decimals) = if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3], i.callerPublicKey))) | |
122 | + | then throw("Only admin can call this function") | |
123 | + | else [Issue(name, description, quantity, decimals, true, unit, 0)] | |
124 | + | ||
125 | + | ||
126 | + | ||
114 | 127 | @Callable(a8) | |
115 | 128 | func call () = { | |
116 | 129 | let a9 = Issue("Asset107112021", "Asset from dApp 1", 100000, 2, true, unit, 0) |
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 | + | ||
10 | + | let adminPubKey1 = base58'H6cFN4f92Tqmvpuuvii5LhcBHugkttZ7QNJ3tmqYLzuE' | |
11 | + | ||
12 | + | let adminPubKey2 = base58'G7cNXePvAHUHmZfXa1eHnvFeH6DuykPC5wm9v9djTKgD' | |
13 | + | ||
14 | + | let adminPubKey3 = base58'G7cNXePvAHUHmZfXa1eHnvFeH6DuykPC5wm9v9djTKgD' | |
9 | 15 | ||
10 | 16 | @Callable(a8) | |
11 | 17 | func init () = [IntegerEntry("3PPH7x7iqobW5ziyiRCic19rQqKr6nPYaK1_asset_balance", 7197869)] | |
12 | 18 | ||
13 | 19 | ||
14 | 20 | ||
15 | 21 | @Callable(i) | |
16 | 22 | func addPools (pools,liquidityTokens,serviceTokens,liquidityTokenDecimals) = { | |
17 | 23 | func generatePoolKeys (accumulated,pool) = IntegerEntry((pool + "_asset_balance"), 0) :: accumulated | |
18 | 24 | ||
19 | 25 | func generatePoolLiquidityTokenKeys (accumulated,pool) = { | |
20 | 26 | let poolIndex = value(indexOf(pools, pool)) | |
21 | 27 | let liquidityToken = liquidityTokens[poolIndex] | |
22 | 28 | StringEntry((pool + "_liquidity_token"), liquidityToken) :: accumulated | |
23 | 29 | } | |
24 | 30 | ||
25 | 31 | func generatePoolServiceTokenKeys (accumulated,pool) = { | |
26 | 32 | let poolIndex = value(indexOf(pools, pool)) | |
27 | 33 | let liquidityToken = serviceTokens[poolIndex] | |
28 | 34 | StringEntry((pool + "_service_token"), liquidityToken) :: accumulated | |
29 | 35 | } | |
30 | 36 | ||
31 | 37 | func generatePoolLiquidityTokenDecimalKeys (accumulated,pool) = { | |
32 | 38 | let poolIndex = value(indexOf(pools, pool)) | |
33 | 39 | let liquidityToken = liquidityTokenDecimals[poolIndex] | |
34 | 40 | IntegerEntry((pool + "_service_token"), liquidityToken) :: accumulated | |
35 | 41 | } | |
36 | 42 | ||
37 | 43 | func generatePoolActiveKeys (accumulated,pool) = BooleanEntry((pool + "_active"), true) :: accumulated | |
38 | 44 | ||
39 | 45 | let poolBalanceKeys = { | |
40 | 46 | let $l = pools | |
41 | 47 | let $s = size($l) | |
42 | 48 | let $acc0 = nil | |
43 | 49 | func 1 ($a,$i) = if (($i >= $s)) | |
44 | 50 | then $a | |
45 | 51 | else generatePoolKeys($a, $l[$i]) | |
46 | 52 | ||
47 | 53 | func 2 ($a,$i) = if (($i >= $s)) | |
48 | 54 | then $a | |
49 | 55 | else throw("List size exceeds 20") | |
50 | 56 | ||
51 | 57 | 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) | |
52 | 58 | } | |
53 | 59 | let poolLiquidityTokenKeys = { | |
54 | 60 | let $l = pools | |
55 | 61 | let $s = size($l) | |
56 | 62 | let $acc0 = nil | |
57 | 63 | func 1 ($a,$i) = if (($i >= $s)) | |
58 | 64 | then $a | |
59 | 65 | else generatePoolLiquidityTokenKeys($a, $l[$i]) | |
60 | 66 | ||
61 | 67 | func 2 ($a,$i) = if (($i >= $s)) | |
62 | 68 | then $a | |
63 | 69 | else throw("List size exceeds 20") | |
64 | 70 | ||
65 | 71 | 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) | |
66 | 72 | } | |
67 | 73 | let poolServiceTokenKeys = { | |
68 | 74 | let $l = pools | |
69 | 75 | let $s = size($l) | |
70 | 76 | let $acc0 = nil | |
71 | 77 | func 1 ($a,$i) = if (($i >= $s)) | |
72 | 78 | then $a | |
73 | 79 | else generatePoolServiceTokenKeys($a, $l[$i]) | |
74 | 80 | ||
75 | 81 | func 2 ($a,$i) = if (($i >= $s)) | |
76 | 82 | then $a | |
77 | 83 | else throw("List size exceeds 20") | |
78 | 84 | ||
79 | 85 | 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) | |
80 | 86 | } | |
81 | 87 | let poolLiquidityTokenDecimalKeys = { | |
82 | 88 | let $l = pools | |
83 | 89 | let $s = size($l) | |
84 | 90 | let $acc0 = nil | |
85 | 91 | func 1 ($a,$i) = if (($i >= $s)) | |
86 | 92 | then $a | |
87 | 93 | else generatePoolLiquidityTokenDecimalKeys($a, $l[$i]) | |
88 | 94 | ||
89 | 95 | func 2 ($a,$i) = if (($i >= $s)) | |
90 | 96 | then $a | |
91 | 97 | else throw("List size exceeds 20") | |
92 | 98 | ||
93 | 99 | 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) | |
94 | 100 | } | |
95 | 101 | let poolActiveKeys = { | |
96 | 102 | let $l = pools | |
97 | 103 | let $s = size($l) | |
98 | 104 | let $acc0 = nil | |
99 | 105 | func 1 ($a,$i) = if (($i >= $s)) | |
100 | 106 | then $a | |
101 | 107 | else generatePoolActiveKeys($a, $l[$i]) | |
102 | 108 | ||
103 | 109 | func 2 ($a,$i) = if (($i >= $s)) | |
104 | 110 | then $a | |
105 | 111 | else throw("List size exceeds 20") | |
106 | 112 | ||
107 | 113 | 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) | |
108 | 114 | } | |
109 | 115 | ((((poolBalanceKeys ++ poolLiquidityTokenKeys) ++ poolServiceTokenKeys) ++ poolLiquidityTokenDecimalKeys) ++ poolActiveKeys) | |
110 | 116 | } | |
111 | 117 | ||
112 | 118 | ||
113 | 119 | ||
120 | + | @Callable(i) | |
121 | + | func issueToken (name,description,quantity,decimals) = if (!(containsElement([adminPubKey1, adminPubKey2, adminPubKey3], i.callerPublicKey))) | |
122 | + | then throw("Only admin can call this function") | |
123 | + | else [Issue(name, description, quantity, decimals, true, unit, 0)] | |
124 | + | ||
125 | + | ||
126 | + | ||
114 | 127 | @Callable(a8) | |
115 | 128 | func call () = { | |
116 | 129 | let a9 = Issue("Asset107112021", "Asset from dApp 1", 100000, 2, true, unit, 0) | |
117 | 130 | let a10 = Issue("Asset207112021", "Asset from dApp 2", 100000, 2, true, unit, 0) | |
118 | 131 | [a10, a9] | |
119 | 132 | } | |
120 | 133 | ||
121 | 134 | ||
122 | 135 | ||
123 | 136 | @Callable(i) | |
124 | 137 | func deposit (pool) = { | |
125 | 138 | let amount = i.payments[0].amount | |
126 | 139 | let assetId = i.payments[0].assetId | |
127 | 140 | let poolAmountKey = (pool + "_asset_balance") | |
128 | 141 | let userAddress = toString(i.caller) | |
129 | 142 | let userPoolAmountKey = (((pool + "_") + userAddress) + "_asset_balance") | |
130 | 143 | let dAppAssetAddress = getStringValue(this, (pool + "_service_token")) | |
131 | 144 | let poolAmount = getIntegerValue(this, poolAmountKey) | |
132 | 145 | let userAmount = match getInteger(userPoolAmountKey) { | |
133 | 146 | case int: Int => | |
134 | 147 | int | |
135 | 148 | case nothing => | |
136 | 149 | 0 | |
137 | 150 | } | |
138 | 151 | let newPoolAmount = (poolAmount + amount) | |
139 | 152 | let userAmountWithoutFee = ((amount - fraction(amount, 1, depositFee, HALFUP)) - fraction(amount, 1, controllerFee, HALFUP)) | |
140 | 153 | let newUserPoolAmount = (userAmount + userAmountWithoutFee) | |
141 | 154 | [Reissue(fromBase58String(dAppAssetAddress), userAmountWithoutFee, true), ScriptTransfer(i.caller, userAmountWithoutFee, fromBase58String(dAppAssetAddress)), IntegerEntry(poolAmountKey, newPoolAmount), IntegerEntry(userPoolAmountKey, newUserPoolAmount)] | |
142 | 155 | } | |
143 | 156 | ||
144 | 157 | ||
145 | 158 | ||
146 | 159 | @Callable(i) | |
147 | 160 | func withdraw (pool,userEarned) = { | |
148 | 161 | let amount = i.payments[0].amount | |
149 | 162 | let assetId = i.payments[0].assetId | |
150 | 163 | let poolAmountKey = (pool + "_asset_balance") | |
151 | 164 | let userAddress = toString(i.caller) | |
152 | 165 | let userPoolAmountKey = (((pool + "_") + userAddress) + "_asset_balance") | |
153 | 166 | let userPoolEarnedKey = (((pool + "_") + userAddress) + "_earned") | |
154 | 167 | let poolAmount = getIntegerValue(this, poolAmountKey) | |
155 | 168 | let userAmount = match getInteger(userPoolAmountKey) { | |
156 | 169 | case int: Int => | |
157 | 170 | int | |
158 | 171 | case nothing => | |
159 | 172 | 0 | |
160 | 173 | } | |
161 | 174 | let userEarnedBefore = match getInteger(userPoolEarnedKey) { | |
162 | 175 | case int: Int => | |
163 | 176 | int | |
164 | 177 | case nothing => | |
165 | 178 | 0 | |
166 | 179 | } | |
167 | 180 | let liquidutyAssetAddress = getStringValue(this, (pool + "_liquidity_token")) | |
168 | 181 | let liquidityTokenDecimal = match assetInfo(fromBase58String(liquidutyAssetAddress)) { | |
169 | 182 | case asset: Asset => | |
170 | 183 | asset.decimals | |
171 | 184 | case _ => | |
172 | 185 | throw("Can't find asset") | |
173 | 186 | } | |
174 | 187 | let dAppAssetAddress = getStringValue(this, (pool + "_service_token")) | |
175 | 188 | let userEarnedTotal = (userEarned + userEarnedBefore) | |
176 | 189 | let amountWithoutFee = ((amount - fraction(amount, 1, platformFee, HALFUP)) - fraction(amount, 1, controllerFee, HALFUP)) | |
177 | 190 | let newPoolAmount = (poolAmount - amountWithoutFee) | |
178 | 191 | if ((userAmount >= amount)) | |
179 | 192 | then { | |
180 | 193 | let newUserPoolAmount = (userAmount - amountWithoutFee) | |
181 | 194 | [Burn(fromBase58String(dAppAssetAddress), amountWithoutFee), ScriptTransfer(i.caller, amountWithoutFee, fromBase58String(liquidutyAssetAddress)), IntegerEntry(poolAmountKey, newPoolAmount), IntegerEntry(userPoolAmountKey, newUserPoolAmount), IntegerEntry(userPoolEarnedKey, userEarnedTotal)] | |
182 | 195 | } | |
183 | 196 | else throw("You have not such balance for withdraw") | |
184 | 197 | } | |
185 | 198 | ||
186 | 199 | ||
187 | 200 | @Verifier(b6) | |
188 | 201 | func b7 () = sigVerify(b6.bodyBytes, b6.proofs[0], b6.senderPublicKey) | |
189 | 202 |
github/deemru/w8io/169f3d6 49.69 ms ◑