tx · FBnvd9wju4u8exKCUSZX2CocWf9DoQd6ocASMC4ohFr8 3MqzKJcjfKxqGWSA84WR4kQwZksM5vjxiFp: -0.03100000 Waves 2022.12.02 10:02 [2342396] smart account 3MqzKJcjfKxqGWSA84WR4kQwZksM5vjxiFp > SELF 0.00000000 Waves
{ "type": 13, "id": "FBnvd9wju4u8exKCUSZX2CocWf9DoQd6ocASMC4ohFr8", "fee": 3100000, "feeAssetId": null, "timestamp": 1669964578770, "version": 1, "sender": "3MqzKJcjfKxqGWSA84WR4kQwZksM5vjxiFp", "senderPublicKey": "bS6Cchmk25EdDcapkz8W5WkZgthTHHW6sSBbcidSrCb", "proofs": [ "3Y9SdVEJMCJ67mx48K1WdBEu1Kc42nkxdsMPEhPC6ADmi8e7hs2DuBdPBWYqmVGotgtnnjdYWa37uwSG2ogC7Tpv" ], "script": "base64:AAIFAAAAAAAAEYIIAhIJCgcBAQEBAQgBEgASBAoCCAgSAwoBCBIECgIICBIECgIICBIDCgEIEgAiD2dldFN0cmluZ09yRmFpbCIDa2V5IgNTRVAiCEJVRlNDQUxFIgZzY2FsZTgiCHRocm93RXJyIgNtc2ciCGFzU3RyaW5nIgN2YWwiByRtYXRjaDAiBnZhbFN0ciIdY29udmVydFByaWNlQXNzZXRJbnRvSWRvQXNzZXQiEHByaWNlQXNzZXRBbW91bnQiDnByaWNlQXNzZXRNVUxUIgVwcmljZSIJcHJpY2VNVUxUIgxpZG9Bc3NldE1VTFQiD2JQcmljZUFzc2V0TVVMVCINYklkb0Fzc2V0TVVMVCIOYlByaWNlQXNzZXRCVUYiD2JBbW91bnRBc3NldEJVRiIOSWR4Q2ZnSWRvU3RhcnQiEUlkeENmZ0lkb0R1cmF0aW9uIhBJZHhDZmdDbGFpbVN0YXJ0IhNJZHhDZmdDbGFpbUR1cmF0aW9uIgtJZHhDZmdQcmljZSIPSWR4Q2ZnUHJpY2VNdWx0IhBJZHhDZmdJZG9Bc3NldElkIhJJZHhDZmdJZG9Bc3NldE11bHQ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zAAAAAAAAAAAABQAAAAJkRA4NmAg=", "chainId": 84, "height": 2342396, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 3sPadFxgc8LAsik5dQXHHJReVUMLqn1oktMiKqcPLxRo Next: 66bMEiSNmpTttXxVkdFTYByADvqAa69uZAg3M3HSECZJ Diff:
Old | New | Differences | |
---|---|---|---|
542 | 542 | let evaluateResult = split(asString(invoke(this, "claimREADONLY", [priceAssetId58, userAddress58], nil)), SEP) | |
543 | 543 | if ((evaluateResult == evaluateResult)) | |
544 | 544 | then { | |
545 | - | let availablePriceAmountToClaim = parseIntValue(evaluateResult[ | |
545 | + | let availablePriceAmountToClaim = parseIntValue(evaluateResult[2]) | |
546 | 546 | let checkUnclaimedAssets = if ((availablePriceAmountToClaim == 0)) | |
547 | 547 | then true | |
548 | 548 | else throwErr("user have unclaimed assets") | |
563 | 563 | let totals = split(value(getString(keyTotals())), SEP) | |
564 | 564 | let totalsTotalAmount = parseIntValue(totals[IdxInvTotalAmount]) | |
565 | 565 | let totalsRemainingAmount = parseIntValue(totals[IdxInvRemainingAmount]) | |
566 | - | let totalsClaimedPriceAssetAmount = parseIntValue(totals[ | |
567 | - | let totalsClaimedIdoAssetAmount = parseIntValue(totals[ | |
566 | + | let totalsClaimedPriceAssetAmount = parseIntValue(totals[IdxInvClaimedPriceAssetAmount]) | |
567 | + | let totalsClaimedIdoAssetAmount = parseIntValue(totals[IdxInvClaimedIdoAssetAmount]) | |
568 | 568 | let totalsLastClaimedHeight = parseIntValue(totals[IdxInvLastClaimedHeight]) | |
569 | 569 | let newTotals = makeString(["%d%d%d%d%d", toString(totalsTotalAmount), toString((totalsRemainingAmount - investorRemainingAmount)), toString(totalsClaimedPriceAssetAmount), toString(totalsClaimedIdoAssetAmount), toString(totalsLastClaimedHeight)], SEP) | |
570 | 570 | let newTotalRemainingAmount = (valueOrElse(getInteger(keyTotalRemainingAmount()), 0) + investorRemainingAmount) | |
611 | 611 | let priceAssetBalance = valueOrElse(getInteger(keyPriceAssetBalance(userAddress58)), 0) | |
612 | 612 | let priceAssetBalanceIdoDecimals = (priceAssetBalance * 100) | |
613 | 613 | let availableIdoAmountToClaimWithPriceAssetBalance = (availableIdoAmountToClaim + priceAssetBalanceIdoDecimals) | |
614 | - | let $ | |
615 | - | let periodMinAvailableToClaim = $ | |
616 | - | let periodTotalAvailableToClaim = $ | |
617 | - | let periodUserAvailableToClaim = $ | |
618 | - | let totalUserAvailableToClaim = $ | |
619 | - | let usdtPriceAssetAllowableRatio = $ | |
620 | - | let currentUsdtPriceAssetRatio = $ | |
621 | - | let endPeriodBlocksLeft = $ | |
622 | - | let updatedCurrentPeriod = $ | |
623 | - | let periodStart = $ | |
624 | - | let periodEnd = $ | |
614 | + | let $t03374334155 = internalClaimV2(priceAssetId58, userAddress58, outAmount, totalsDiff[IdxDiffClaimedPriceAmountIncrement]) | |
615 | + | let periodMinAvailableToClaim = $t03374334155._1 | |
616 | + | let periodTotalAvailableToClaim = $t03374334155._2 | |
617 | + | let periodUserAvailableToClaim = $t03374334155._3 | |
618 | + | let totalUserAvailableToClaim = $t03374334155._4 | |
619 | + | let usdtPriceAssetAllowableRatio = $t03374334155._5 | |
620 | + | let currentUsdtPriceAssetRatio = $t03374334155._6 | |
621 | + | let endPeriodBlocksLeft = $t03374334155._7 | |
622 | + | let updatedCurrentPeriod = $t03374334155._8 | |
623 | + | let periodStart = $t03374334155._9 | |
624 | + | let periodEnd = $t03374334155._10 | |
625 | 625 | let currentPeriodEndHeight = valueOrElse(getInteger(keyPeriodEndHeight(updatedCurrentPeriod)), 0) | |
626 | 626 | let userTotalPriceAssetClaimed = (parseIntValue(readInvestorArrayOrFail(userAddress58)[IdxInvClaimedPriceAssetAmount]) - priceAssetBalance) | |
627 | 627 | let resultString = if ((height > currentPeriodEndHeight)) |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | func getStringOrFail (key) = valueOrErrorMessage(getString(key), (("mandatory this." + key) + " is not defined")) | |
5 | 5 | ||
6 | 6 | ||
7 | 7 | let SEP = "__" | |
8 | 8 | ||
9 | 9 | let BUFSCALE = toBigInt(1000000000000000000) | |
10 | 10 | ||
11 | 11 | let scale8 = 100000000 | |
12 | 12 | ||
13 | 13 | func throwErr (msg) = throw(makeString(["ido.ride:", msg], " ")) | |
14 | 14 | ||
15 | 15 | ||
16 | 16 | func asString (val) = match val { | |
17 | 17 | case valStr: String => | |
18 | 18 | valStr | |
19 | 19 | case _ => | |
20 | 20 | throw("fail to cast into String") | |
21 | 21 | } | |
22 | 22 | ||
23 | 23 | ||
24 | 24 | func convertPriceAssetIntoIdoAsset (priceAssetAmount,priceAssetMULT,price,priceMULT,idoAssetMULT) = { | |
25 | 25 | let bPriceAssetMULT = toBigInt(priceAssetMULT) | |
26 | 26 | let bIdoAssetMULT = toBigInt(idoAssetMULT) | |
27 | 27 | let bPriceAssetBUF = fraction(toBigInt(priceAssetAmount), BUFSCALE, bPriceAssetMULT) | |
28 | 28 | let bAmountAssetBUF = fraction(bPriceAssetBUF, toBigInt(priceMULT), toBigInt(price)) | |
29 | 29 | toInt(fraction(bAmountAssetBUF, toBigInt(idoAssetMULT), BUFSCALE)) | |
30 | 30 | } | |
31 | 31 | ||
32 | 32 | ||
33 | 33 | let IdxCfgIdoStart = 1 | |
34 | 34 | ||
35 | 35 | let IdxCfgIdoDuration = 2 | |
36 | 36 | ||
37 | 37 | let IdxCfgClaimStart = 3 | |
38 | 38 | ||
39 | 39 | let IdxCfgClaimDuration = 4 | |
40 | 40 | ||
41 | 41 | let IdxCfgPrice = 5 | |
42 | 42 | ||
43 | 43 | let IdxCfgPriceMult = 6 | |
44 | 44 | ||
45 | 45 | let IdxCfgIdoAssetId = 7 | |
46 | 46 | ||
47 | 47 | let IdxCfgIdoAssetMult = 8 | |
48 | 48 | ||
49 | 49 | let IdxCfgPriceAssetId = 9 | |
50 | 50 | ||
51 | 51 | let IdxCfgPriceAssetMult = 10 | |
52 | 52 | ||
53 | 53 | let IdxCfgMinInvestAmount = 11 | |
54 | 54 | ||
55 | 55 | func fromatConfigS (idoStart,idoDuration,claimStart,claimDuration,price,priceMult,idoAssetId58,idoAssetMult,priceAssetId58,priceAssetMult,minInvestAmount,totalIdoAssetToSell) = makeString(["%d%d%d%d%d%d%s%d%s%d%d%d", idoStart, idoDuration, claimStart, claimDuration, price, priceMult, idoAssetId58, idoAssetMult, priceAssetId58, priceAssetMult, minInvestAmount, totalIdoAssetToSell], SEP) | |
56 | 56 | ||
57 | 57 | ||
58 | 58 | func fromatConfig (idoStart,idoDuration,claimStart,claimDuration,price,priceMult,idoAssetId58,idoAssetMult,priceAssetId58,priceAssetMult,minInvestAmount,totalIdoAssetToSell) = fromatConfigS(toString(idoStart), toString(idoDuration), toString(claimStart), toString(claimDuration), toString(price), toString(priceMult), idoAssetId58, toString(idoAssetMult), priceAssetId58, toString(priceAssetMult), toString(minInvestAmount), toString(totalIdoAssetToSell)) | |
59 | 59 | ||
60 | 60 | ||
61 | 61 | let IdxInvTotalAmount = 1 | |
62 | 62 | ||
63 | 63 | let IdxInvRemainingAmount = 2 | |
64 | 64 | ||
65 | 65 | let IdxInvClaimedPriceAssetAmount = 3 | |
66 | 66 | ||
67 | 67 | let IdxInvClaimedIdoAssetAmount = 4 | |
68 | 68 | ||
69 | 69 | let IdxInvLastClaimedHeight = 5 | |
70 | 70 | ||
71 | 71 | func formatInvestorS (totalAmount,remainingAmount,claimedPriceAssetAmount,claimedIdoAssetAmount,lastClaimedHeight) = makeString(["%d%d%d%d%d", totalAmount, remainingAmount, claimedPriceAssetAmount, claimedIdoAssetAmount, lastClaimedHeight], SEP) | |
72 | 72 | ||
73 | 73 | ||
74 | 74 | func formatInvestor (totalAmount,remainingAmount,claimedPriceAssetAmount,claimedIdoAssetAmount,lastClaimedHeight) = formatInvestorS(toString(totalAmount), toString(remainingAmount), toString(claimedPriceAssetAmount), toString(claimedIdoAssetAmount), toString(lastClaimedHeight)) | |
75 | 75 | ||
76 | 76 | ||
77 | 77 | func formatHistoryRecord (priceAssetAmount,idoAssetAmount) = makeString(["%d%d%d%d", toString(height), toString(lastBlock.timestamp), toString(priceAssetAmount), toString(idoAssetAmount)], SEP) | |
78 | 78 | ||
79 | 79 | ||
80 | 80 | func keyConfig () = "%s__config" | |
81 | 81 | ||
82 | 82 | ||
83 | 83 | func keyInvestor (userAddress) = ("%s__" + userAddress) | |
84 | 84 | ||
85 | 85 | ||
86 | 86 | func keyTotals () = "%s__totals" | |
87 | 87 | ||
88 | 88 | ||
89 | 89 | func keyOperationHistoryRecord (type,userAddress,txId58) = makeString(["%s%s%s%s__history", type, userAddress, txId58], SEP) | |
90 | 90 | ||
91 | 91 | ||
92 | 92 | func keyUSDNClaimDisabled () = "%s__usdnClaimDisabled" | |
93 | 93 | ||
94 | 94 | ||
95 | 95 | func keyUSDNClaimEndHeight () = "%s__usdnClaimEndHeight" | |
96 | 96 | ||
97 | 97 | ||
98 | 98 | func keyPeriodLength () = makeString(["%s", "periodLength"], SEP) | |
99 | 99 | ||
100 | 100 | ||
101 | 101 | func keyCurrentPeriod () = makeString(["%s", "currentPeriod"], SEP) | |
102 | 102 | ||
103 | 103 | ||
104 | 104 | func keyPeriodStartHeight (periodNum) = makeString(["%s%s", "periodStartHeight", toString(periodNum)], SEP) | |
105 | 105 | ||
106 | 106 | ||
107 | 107 | func keyPeriodEndHeight (periodNum) = makeString(["%s%s", "periodEndHeight", toString(periodNum)], SEP) | |
108 | 108 | ||
109 | 109 | ||
110 | 110 | func keyUsdtPriceAssetAllowableRatio () = makeString(["%s", "usdtPriceAssetAllowableRatio"], SEP) | |
111 | 111 | ||
112 | 112 | ||
113 | 113 | func keyTotalPeriodAllowance (assetId) = makeString(["%s%s", "totalPeriodAllowance", assetId], SEP) | |
114 | 114 | ||
115 | 115 | ||
116 | 116 | func keyUserPeriodAllowance (assetId) = makeString(["%s%s", "userPeriodAllowance", assetId], SEP) | |
117 | 117 | ||
118 | 118 | ||
119 | 119 | func keyPeriodTotalAvailableToClaim (assetId,periodNum) = makeString(["%s%s%s", "periodTotalAvailableToClaim", assetId, toString(periodNum)], SEP) | |
120 | 120 | ||
121 | 121 | ||
122 | 122 | func keyPeriodUserAvailableToClaim (assetId,periodNum,userAddress) = makeString(["%s%s%s%s", "periodUserAvailableToClaim", assetId, toString(periodNum), userAddress], SEP) | |
123 | 123 | ||
124 | 124 | ||
125 | 125 | func keyUsdtPriceAssetStablePool () = makeString(["%s", "usdtPriceAssetStablePool"], SEP) | |
126 | 126 | ||
127 | 127 | ||
128 | 128 | func keyUsdtAssetId () = makeString(["%s", "usdtAssetId"], SEP) | |
129 | 129 | ||
130 | 130 | ||
131 | 131 | func keyPriceAssetBalance (address) = makeString(["%s%s", "priceAssetBalance", address], SEP) | |
132 | 132 | ||
133 | 133 | ||
134 | 134 | func keyInvestorRemainingAmount (address) = makeString(["%s%s", "investorRemainingAmount", address], SEP) | |
135 | 135 | ||
136 | 136 | ||
137 | 137 | func keyTotalRemainingAmount () = makeString(["%s", "totalRemainingAmount"], SEP) | |
138 | 138 | ||
139 | 139 | ||
140 | 140 | func keyManagerPublicKey () = "%s__managerPublicKey" | |
141 | 141 | ||
142 | 142 | ||
143 | 143 | func keyPendingManagerPublicKey () = "%s__pendingManagerPublicKey" | |
144 | 144 | ||
145 | 145 | ||
146 | 146 | func readConfigArray () = split(getStringOrFail(keyConfig()), SEP) | |
147 | 147 | ||
148 | 148 | ||
149 | 149 | func readTotalsArrayOrDefaultByCustomKey (customKey) = split(valueOrElse(getString(customKey), formatInvestorS("0", "0", "0", "0", "0")), SEP) | |
150 | 150 | ||
151 | 151 | ||
152 | 152 | func readTotalsArrayOrDefault () = readTotalsArrayOrDefaultByCustomKey(keyTotals()) | |
153 | 153 | ||
154 | 154 | ||
155 | 155 | func readInvestorArrayOrDefault (userAddress) = readTotalsArrayOrDefaultByCustomKey(keyInvestor(userAddress)) | |
156 | 156 | ||
157 | 157 | ||
158 | 158 | func readInvestorArrayOrFail (userAddress) = split(getStringOrFail(keyInvestor(userAddress)), SEP) | |
159 | 159 | ||
160 | 160 | ||
161 | 161 | let IdxDiffTotalIncrement = 0 | |
162 | 162 | ||
163 | 163 | let IdxDiffRemainingPriceAmountIncrement = 1 | |
164 | 164 | ||
165 | 165 | let IdxDiffClaimedPriceAmountIncrement = 2 | |
166 | 166 | ||
167 | 167 | let IdxDiffClaimedIdoAssetAmountIncrement = 3 | |
168 | 168 | ||
169 | 169 | func TotalsEntry (key,origArray,incrementDiff,newLastClaimedHeight,priceAssetBalance) = { | |
170 | 170 | let totalAmount = parseIntValue(origArray[IdxInvTotalAmount]) | |
171 | 171 | let remainingAmount = parseIntValue(origArray[IdxInvRemainingAmount]) | |
172 | 172 | let claimedPriceAssetAmount = parseIntValue(origArray[IdxInvClaimedPriceAssetAmount]) | |
173 | 173 | let claimedIdoAssetAmount = parseIntValue(origArray[IdxInvClaimedIdoAssetAmount]) | |
174 | 174 | let lastClaimedHeight = parseIntValue(origArray[IdxInvLastClaimedHeight]) | |
175 | 175 | let newTotalAmount = (totalAmount + incrementDiff[IdxDiffTotalIncrement]) | |
176 | 176 | let newRemainingAmount = (remainingAmount + incrementDiff[IdxDiffRemainingPriceAmountIncrement]) | |
177 | 177 | let cfgArray = readConfigArray() | |
178 | 178 | let priceAssetId58 = cfgArray[IdxCfgPriceAssetId] | |
179 | 179 | let priceAssetDecimals = value(assetInfo(fromBase58String(priceAssetId58))).decimals | |
180 | 180 | let priceAssetBalancePriceAssetDecimals = fraction(priceAssetBalance, scale8, pow(10, 0, priceAssetDecimals, 0, 0, DOWN)) | |
181 | 181 | let newClaimedPriceAssetAmount = ((claimedPriceAssetAmount + incrementDiff[IdxDiffClaimedPriceAmountIncrement]) - priceAssetBalance) | |
182 | 182 | let newClaimedIdoAssetAmount = ((claimedIdoAssetAmount + incrementDiff[IdxDiffClaimedIdoAssetAmountIncrement]) + priceAssetBalancePriceAssetDecimals) | |
183 | 183 | let entries = if ((0 > newRemainingAmount)) | |
184 | 184 | then { | |
185 | 185 | let diff = ((newTotalAmount - newClaimedPriceAssetAmount) - newClaimedIdoAssetAmount) | |
186 | 186 | let newLogicRemainingAmount = if ((0 > diff)) | |
187 | 187 | then 0 | |
188 | 188 | else diff | |
189 | 189 | StringEntry(key, formatInvestor(newTotalAmount, newLogicRemainingAmount, newClaimedPriceAssetAmount, newClaimedIdoAssetAmount, newLastClaimedHeight)) | |
190 | 190 | } | |
191 | 191 | else StringEntry(key, formatInvestor(newTotalAmount, newRemainingAmount, newClaimedPriceAssetAmount, newClaimedIdoAssetAmount, newLastClaimedHeight)) | |
192 | 192 | entries | |
193 | 193 | } | |
194 | 194 | ||
195 | 195 | ||
196 | 196 | func InvestOperationHistoryEntry (userAddress,priceAssetAmount,idoAssetAmount,txId) = StringEntry(keyOperationHistoryRecord("invest", userAddress, toBase58String(txId)), formatHistoryRecord(priceAssetAmount, idoAssetAmount)) | |
197 | 197 | ||
198 | 198 | ||
199 | 199 | func ClaimOperationHistoryEntry (userAddress,priceAssetAmount,idoAssetAmount,txId) = StringEntry(keyOperationHistoryRecord("claim", userAddress, toBase58String(txId)), formatHistoryRecord(priceAssetAmount, idoAssetAmount)) | |
200 | 200 | ||
201 | 201 | ||
202 | 202 | func internalClaim (claimedAssetId58,userAddress,txId) = { | |
203 | 203 | let cfgArray = readConfigArray() | |
204 | 204 | let claimStart = parseIntValue(cfgArray[IdxCfgClaimStart]) | |
205 | 205 | let claimDuration = parseIntValue(cfgArray[IdxCfgClaimDuration]) | |
206 | 206 | let claimEnd = (claimStart + claimDuration) | |
207 | 207 | let price = parseIntValue(cfgArray[IdxCfgPrice]) | |
208 | 208 | let priceMult = parseIntValue(cfgArray[IdxCfgPriceMult]) | |
209 | 209 | let idoAssetId58 = cfgArray[IdxCfgIdoAssetId] | |
210 | 210 | let idoAssetId = fromBase58String(idoAssetId58) | |
211 | 211 | let idoAssetMult = parseIntValue(cfgArray[IdxCfgIdoAssetMult]) | |
212 | 212 | let priceAssetId58 = cfgArray[IdxCfgPriceAssetId] | |
213 | 213 | let priceAssetId = fromBase58String(priceAssetId58) | |
214 | 214 | let priceAssetMult = parseIntValue(cfgArray[IdxCfgPriceAssetMult]) | |
215 | 215 | let userAddress58 = toString(userAddress) | |
216 | 216 | let origInvestArray = readInvestorArrayOrFail(userAddress58) | |
217 | 217 | let investTotalAmount = parseIntValue(origInvestArray[IdxInvTotalAmount]) | |
218 | 218 | let investLastClaimedHeightTMP = parseIntValue(origInvestArray[IdxInvLastClaimedHeight]) | |
219 | 219 | let investLastClaimedHeight = if ((claimStart >= investLastClaimedHeightTMP)) | |
220 | 220 | then claimStart | |
221 | 221 | else investLastClaimedHeightTMP | |
222 | 222 | let newClaimPeriodHeight = if ((height > claimEnd)) | |
223 | 223 | then claimEnd | |
224 | 224 | else if ((claimStart > height)) | |
225 | 225 | then claimStart | |
226 | 226 | else height | |
227 | 227 | let claimingBlocks = (newClaimPeriodHeight - investLastClaimedHeight) | |
228 | 228 | let claimingPriceAssetAmount = fraction(investTotalAmount, claimingBlocks, claimDuration) | |
229 | 229 | let claimingIdoAssetAmount = convertPriceAssetIntoIdoAsset(claimingPriceAssetAmount, priceAssetMult, price, priceMult, idoAssetMult) | |
230 | 230 | let isUSDN = (claimedAssetId58 == priceAssetId58) | |
231 | 231 | let isUSDNClaimDisabled = valueOrElse(getBoolean(keyUSDNClaimDisabled()), false) | |
232 | 232 | let checks = [if (!(if (isUSDN) | |
233 | 233 | then isUSDNClaimDisabled | |
234 | 234 | else false)) | |
235 | 235 | then true | |
236 | 236 | else throw("USDN claim is disabled")] | |
237 | 237 | if ((checks == checks)) | |
238 | 238 | then if ((claimedAssetId58 == priceAssetId58)) | |
239 | 239 | then $Tuple6([0, -(claimingPriceAssetAmount), claimingPriceAssetAmount, 0], claimingPriceAssetAmount, priceAssetId, origInvestArray, newClaimPeriodHeight, [claimingPriceAssetAmount, claimingIdoAssetAmount]) | |
240 | 240 | else if ((claimedAssetId58 == idoAssetId58)) | |
241 | 241 | then $Tuple6([0, -(claimingPriceAssetAmount), 0, claimingIdoAssetAmount], claimingIdoAssetAmount, idoAssetId, origInvestArray, newClaimPeriodHeight, [claimingPriceAssetAmount, claimingIdoAssetAmount]) | |
242 | 242 | else throw(("unsupported assetId: " + claimedAssetId58)) | |
243 | 243 | else throw("Strict value is not equal to itself.") | |
244 | 244 | } | |
245 | 245 | ||
246 | 246 | ||
247 | 247 | func internalClaimV2 (priceAssetId58,userAddress58,outAmount,totalUserAvailableToClaim) = { | |
248 | 248 | let totalPeriodPriceAssetAllowance = value(getInteger(keyTotalPeriodAllowance(priceAssetId58))) | |
249 | 249 | let userPeriodPriceAssetAllowance = value(getInteger(keyUserPeriodAllowance(priceAssetId58))) | |
250 | 250 | let periodLength = value(getInteger(keyPeriodLength())) | |
251 | 251 | let currentPeriod = valueOrElse(getInteger(keyCurrentPeriod()), 0) | |
252 | 252 | let zeroPeriodEndHeighIsDefined = isDefined(getInteger(keyPeriodEndHeight(0))) | |
253 | 253 | let $t01298714857 = if ((currentPeriod > 0)) | |
254 | 254 | then { | |
255 | 255 | let lastPeriodStartHeight = value(getInteger(keyPeriodStartHeight(currentPeriod))) | |
256 | 256 | let lastPeriodEndHeight = value(getInteger(keyPeriodEndHeight(currentPeriod))) | |
257 | 257 | let $t01324713952 = if ((height > lastPeriodEndHeight)) | |
258 | 258 | then { | |
259 | 259 | let updatedCurrentPeriod = (currentPeriod + 1) | |
260 | 260 | let periodStart = if ((height > (lastPeriodEndHeight + periodLength))) | |
261 | 261 | then { | |
262 | 262 | let blocksToLastPeriodStart = ((height - lastPeriodEndHeight) % periodLength) | |
263 | 263 | if ((blocksToLastPeriodStart == 0)) | |
264 | 264 | then ((height - periodLength) + 1) | |
265 | 265 | else (height - blocksToLastPeriodStart) | |
266 | 266 | } | |
267 | 267 | else (lastPeriodEndHeight + 1) | |
268 | 268 | let periodEnd = ((periodStart + periodLength) - 1) | |
269 | 269 | $Tuple3(updatedCurrentPeriod, periodStart, periodEnd) | |
270 | 270 | } | |
271 | 271 | else $Tuple3(currentPeriod, lastPeriodStartHeight, lastPeriodEndHeight) | |
272 | 272 | let updatedCurrentPeriod = $t01324713952._1 | |
273 | 273 | let periodStart = $t01324713952._2 | |
274 | 274 | let periodEnd = $t01324713952._3 | |
275 | 275 | $Tuple3(updatedCurrentPeriod, periodStart, periodEnd) | |
276 | 276 | } | |
277 | 277 | else if (zeroPeriodEndHeighIsDefined) | |
278 | 278 | then { | |
279 | 279 | let zeroPeriodStartHeight = value(getInteger(keyPeriodStartHeight(0))) | |
280 | 280 | let zeroPeriodEndHeight = value(getInteger(keyPeriodEndHeight(0))) | |
281 | 281 | let $t01420714589 = if ((height > zeroPeriodEndHeight)) | |
282 | 282 | then { | |
283 | 283 | let updatedCurrentPeriod = (currentPeriod + 1) | |
284 | 284 | let periodStart = (zeroPeriodEndHeight + 1) | |
285 | 285 | let periodEnd = ((periodStart + periodLength) - 1) | |
286 | 286 | $Tuple3(updatedCurrentPeriod, periodStart, periodEnd) | |
287 | 287 | } | |
288 | 288 | else $Tuple3(currentPeriod, zeroPeriodStartHeight, zeroPeriodEndHeight) | |
289 | 289 | let updatedCurrentPeriod = $t01420714589._1 | |
290 | 290 | let periodStart = $t01420714589._2 | |
291 | 291 | let periodEnd = $t01420714589._3 | |
292 | 292 | $Tuple3(updatedCurrentPeriod, periodStart, periodEnd) | |
293 | 293 | } | |
294 | 294 | else $Tuple3(currentPeriod, valueOrElse(getInteger(keyPeriodStartHeight(currentPeriod)), height), valueOrElse(getInteger(keyPeriodEndHeight(currentPeriod)), ((height + periodLength) - 1))) | |
295 | 295 | let updatedCurrentPeriod = $t01298714857._1 | |
296 | 296 | let periodStart = $t01298714857._2 | |
297 | 297 | let periodEnd = $t01298714857._3 | |
298 | 298 | let periodTotalAvailableToClaim = valueOrElse(getInteger(keyPeriodTotalAvailableToClaim(priceAssetId58, updatedCurrentPeriod)), totalPeriodPriceAssetAllowance) | |
299 | 299 | let periodUserAvailableToClaim = valueOrElse(getInteger(keyPeriodUserAvailableToClaim(priceAssetId58, updatedCurrentPeriod, userAddress58)), userPeriodPriceAssetAllowance) | |
300 | 300 | let priceAssetBalance = valueOrElse(getInteger(keyPriceAssetBalance(userAddress58)), 0) | |
301 | 301 | let periodMinAvailableToClaim = min([(outAmount + priceAssetBalance), periodTotalAvailableToClaim, periodUserAvailableToClaim]) | |
302 | 302 | let usdtPriceAssetAllowableRatio = value(getInteger(keyUsdtPriceAssetAllowableRatio())) | |
303 | 303 | let putOneTknV2PriceAssetAmount = scale8 | |
304 | 304 | let $t01561215865 = { | |
305 | 305 | let @ = invoke(addressFromStringValue(value(getString(keyUsdtPriceAssetStablePool()))), "putOneTknV2WithoutTakeFeeREADONLY", [putOneTknV2PriceAssetAmount, priceAssetId58], nil) | |
306 | 306 | if ($isInstanceOf(@, "(Int, Int, Int)")) | |
307 | 307 | then @ | |
308 | 308 | else throw("Couldn't cast Any to (Int, Int, Int)") | |
309 | 309 | } | |
310 | 310 | if (($t01561215865 == $t01561215865)) | |
311 | 311 | then { | |
312 | 312 | let bonus = $t01561215865._3 | |
313 | 313 | let feeAmount = $t01561215865._2 | |
314 | 314 | let lpAmount = $t01561215865._1 | |
315 | 315 | let usdtAssetId = value(getString(keyUsdtAssetId())) | |
316 | 316 | let $t01592716145 = { | |
317 | 317 | let @ = invoke(addressFromStringValue(value(getString(keyUsdtPriceAssetStablePool()))), "getOneTknV2READONLY", [usdtAssetId, lpAmount], nil) | |
318 | 318 | if ($isInstanceOf(@, "(Int, Int)")) | |
319 | 319 | then @ | |
320 | 320 | else throw("Couldn't cast Any to (Int, Int)") | |
321 | 321 | } | |
322 | 322 | if (($t01592716145 == $t01592716145)) | |
323 | 323 | then { | |
324 | 324 | let getOneTknV2FeeAmount = $t01592716145._2 | |
325 | 325 | let usdtAmount = $t01592716145._1 | |
326 | 326 | let currentUsdtPriceAssetRatio = fraction(putOneTknV2PriceAssetAmount, scale8, usdtAmount) | |
327 | 327 | let endPeriodBlocksLeft = (periodEnd - height) | |
328 | 328 | $Tuple10(periodMinAvailableToClaim, periodTotalAvailableToClaim, periodUserAvailableToClaim, totalUserAvailableToClaim, usdtPriceAssetAllowableRatio, currentUsdtPriceAssetRatio, endPeriodBlocksLeft, updatedCurrentPeriod, periodStart, periodEnd) | |
329 | 329 | } | |
330 | 330 | else throw("Strict value is not equal to itself.") | |
331 | 331 | } | |
332 | 332 | else throw("Strict value is not equal to itself.") | |
333 | 333 | } | |
334 | 334 | ||
335 | 335 | ||
336 | 336 | func managerPublicKeyOrUnit () = match getString(keyManagerPublicKey()) { | |
337 | 337 | case s: String => | |
338 | 338 | fromBase58String(s) | |
339 | 339 | case _: Unit => | |
340 | 340 | unit | |
341 | 341 | case _ => | |
342 | 342 | throw("Match error") | |
343 | 343 | } | |
344 | 344 | ||
345 | 345 | ||
346 | 346 | func pendingManagerPublicKeyOrUnit () = match getString(keyPendingManagerPublicKey()) { | |
347 | 347 | case s: String => | |
348 | 348 | fromBase58String(s) | |
349 | 349 | case _: Unit => | |
350 | 350 | unit | |
351 | 351 | case _ => | |
352 | 352 | throw("Match error") | |
353 | 353 | } | |
354 | 354 | ||
355 | 355 | ||
356 | 356 | func mustManager (i) = { | |
357 | 357 | let pd = throw("Permission denied") | |
358 | 358 | match managerPublicKeyOrUnit() { | |
359 | 359 | case pk: ByteVector => | |
360 | 360 | if ((i.callerPublicKey == pk)) | |
361 | 361 | then true | |
362 | 362 | else pd | |
363 | 363 | case _: Unit => | |
364 | 364 | if ((i.caller == this)) | |
365 | 365 | then true | |
366 | 366 | else pd | |
367 | 367 | case _ => | |
368 | 368 | throw("Match error") | |
369 | 369 | } | |
370 | 370 | } | |
371 | 371 | ||
372 | 372 | ||
373 | 373 | @Callable(i) | |
374 | 374 | func constructor (idoStart,idoDuration,claimStart,claimDuration,price,priceAssetId58,minInvestAmount) = { | |
375 | 375 | let priceMult = ((100 * 1000) * 1000) | |
376 | 376 | let idoEnd = (idoStart + idoDuration) | |
377 | 377 | if (isDefined(getString(keyConfig()))) | |
378 | 378 | then throw("already initialized") | |
379 | 379 | else if (("3PMEHLx1j6zerarZTYfsGqDeeZqQoMpxq5S" != toString(i.caller))) | |
380 | 380 | then throw("not authorized") | |
381 | 381 | else if ((size(i.payments) != 1)) | |
382 | 382 | then throw("exactly 1 payment must be attached") | |
383 | 383 | else if ((idoEnd >= claimStart)) | |
384 | 384 | then throw("claimStart must be greater than idoEnd") | |
385 | 385 | else { | |
386 | 386 | let pmt = value(i.payments[0]) | |
387 | 387 | let idoAssetId = value(pmt.assetId) | |
388 | 388 | let idoAssetInfo = valueOrErrorMessage(assetInfo(idoAssetId), "fail to load ido asset info") | |
389 | 389 | let idoAssetId58 = toBase58String(idoAssetId) | |
390 | 390 | let idoAssetMult = pow(10, 0, idoAssetInfo.decimals, 0, 0, DOWN) | |
391 | 391 | let priceAssetId = fromBase58String(priceAssetId58) | |
392 | 392 | let priceAssetInfo = valueOrErrorMessage(assetInfo(priceAssetId), "fail to load price asset info") | |
393 | 393 | let priceAssetMult = pow(10, 0, priceAssetInfo.decimals, 0, 0, DOWN) | |
394 | 394 | let origTotalsArray = readTotalsArrayOrDefault() | |
395 | 395 | let totalsDiff = [0, 0, 0, 0] | |
396 | 396 | [StringEntry(keyConfig(), fromatConfig(idoStart, idoDuration, claimStart, claimDuration, price, priceMult, idoAssetId58, idoAssetMult, priceAssetId58, priceAssetMult, minInvestAmount, pmt.amount)), TotalsEntry(keyTotals(), origTotalsArray, totalsDiff, claimStart, 0)] | |
397 | 397 | } | |
398 | 398 | } | |
399 | 399 | ||
400 | 400 | ||
401 | 401 | ||
402 | 402 | @Callable(i) | |
403 | 403 | func invest () = { | |
404 | 404 | let cfgArray = readConfigArray() | |
405 | 405 | let idoStart = parseIntValue(cfgArray[IdxCfgIdoStart]) | |
406 | 406 | let idoDuration = parseIntValue(cfgArray[IdxCfgIdoDuration]) | |
407 | 407 | let idoEnd = (idoStart + idoDuration) | |
408 | 408 | let claimStart = parseIntValue(cfgArray[IdxCfgClaimStart]) | |
409 | 409 | let claimDuration = parseIntValue(cfgArray[IdxCfgClaimDuration]) | |
410 | 410 | let price = parseIntValue(cfgArray[IdxCfgPrice]) | |
411 | 411 | let priceMult = parseIntValue(cfgArray[IdxCfgPriceMult]) | |
412 | 412 | let idoAssetId58 = cfgArray[IdxCfgIdoAssetId] | |
413 | 413 | let idoAssetId = fromBase58String(idoAssetId58) | |
414 | 414 | let idoAssetMult = parseIntValue(cfgArray[IdxCfgIdoAssetMult]) | |
415 | 415 | let priceAssetId58 = cfgArray[IdxCfgPriceAssetId] | |
416 | 416 | let priceAssetId = fromBase58String(priceAssetId58) | |
417 | 417 | let priceAssetMult = parseIntValue(cfgArray[IdxCfgPriceAssetMult]) | |
418 | 418 | let minIvestAmount = parseIntValue(cfgArray[IdxCfgMinInvestAmount]) | |
419 | 419 | let userAddress = toString(i.caller) | |
420 | 420 | if ((idoStart > height)) | |
421 | 421 | then throw("ido has not been started yet") | |
422 | 422 | else if ((height > idoEnd)) | |
423 | 423 | then throw("ido has been already ended") | |
424 | 424 | else if ((size(i.payments) != 1)) | |
425 | 425 | then throw("exactly 1 payment is expected") | |
426 | 426 | else { | |
427 | 427 | let pmt = value(i.payments[0]) | |
428 | 428 | let pmtAssetId = value(pmt.assetId) | |
429 | 429 | let pmtAmount = pmt.amount | |
430 | 430 | if ((pmtAssetId != priceAssetId)) | |
431 | 431 | then throw((("invalid payment asset id: " + toBase58String(pmtAssetId)) + " is expected")) | |
432 | 432 | else { | |
433 | 433 | let origInvestorArray = readInvestorArrayOrDefault(userAddress) | |
434 | 434 | let origTotalsArray = readTotalsArrayOrDefault() | |
435 | 435 | let newPriceTotalAmount = (parseIntValue(origTotalsArray[IdxInvTotalAmount]) + pmtAmount) | |
436 | 436 | let requiredIdoAssetAmount = (newPriceTotalAmount * 100) | |
437 | 437 | if ((requiredIdoAssetAmount > assetBalance(this, idoAssetId))) | |
438 | 438 | then throw("IDO asset has been - sold consider to use smaller payment") | |
439 | 439 | else { | |
440 | 440 | let totalsDiff = [pmtAmount, pmtAmount, 0, 0] | |
441 | 441 | [TotalsEntry(keyInvestor(userAddress), origInvestorArray, totalsDiff, claimStart, 0), TotalsEntry(keyTotals(), origTotalsArray, totalsDiff, claimStart, 0), InvestOperationHistoryEntry(userAddress, pmtAmount, 0, i.transactionId)] | |
442 | 442 | } | |
443 | 443 | } | |
444 | 444 | } | |
445 | 445 | } | |
446 | 446 | ||
447 | 447 | ||
448 | 448 | ||
449 | 449 | @Callable(i) | |
450 | 450 | func claim (claimedAssetId58,userAddress58) = { | |
451 | 451 | let callerAddress58 = toString(i.caller) | |
452 | 452 | if ((userAddress58 != callerAddress58)) | |
453 | 453 | then throw("not authorized") | |
454 | 454 | else { | |
455 | 455 | let cfgArray = readConfigArray() | |
456 | 456 | let priceAssetId58 = cfgArray[IdxCfgPriceAssetId] | |
457 | 457 | let claimResultTuple = internalClaim(claimedAssetId58, i.caller, i.transactionId) | |
458 | 458 | let totalsDiff = claimResultTuple._1 | |
459 | 459 | let outAmount = claimResultTuple._2 | |
460 | 460 | let outAssetId = claimResultTuple._3 | |
461 | 461 | let origInvestArray = claimResultTuple._4 | |
462 | 462 | let newClaimPeriodHeight = claimResultTuple._5 | |
463 | 463 | let claimedPriceAmountFromDiff = totalsDiff[IdxDiffClaimedPriceAmountIncrement] | |
464 | 464 | let claimedIdoAssetAmountFromDiff = totalsDiff[IdxDiffClaimedIdoAssetAmountIncrement] | |
465 | 465 | let priceAssetBalance = valueOrElse(getInteger(keyPriceAssetBalance(userAddress58)), 0) | |
466 | 466 | let priceAssetDecimals = value(assetInfo(fromBase58String(priceAssetId58))).decimals | |
467 | 467 | let entries = if ((claimedAssetId58 == priceAssetId58)) | |
468 | 468 | then { | |
469 | 469 | let $t02205422498 = internalClaimV2(priceAssetId58, userAddress58, outAmount, totalsDiff[IdxDiffClaimedPriceAmountIncrement]) | |
470 | 470 | let periodMinAvailableToClaim = $t02205422498._1 | |
471 | 471 | let periodTotalAvailableToClaim = $t02205422498._2 | |
472 | 472 | let periodUserAvailableToClaim = $t02205422498._3 | |
473 | 473 | let totalUserAvailableToClaim = $t02205422498._4 | |
474 | 474 | let usdtPriceAssetAllowableRatio = $t02205422498._5 | |
475 | 475 | let currentUsdtPriceAssetRatio = $t02205422498._6 | |
476 | 476 | let endPeriodBlocksLeft = $t02205422498._7 | |
477 | 477 | let updatedCurrentPeriod = $t02205422498._8 | |
478 | 478 | let periodStart = $t02205422498._9 | |
479 | 479 | let periodEnd = $t02205422498._10 | |
480 | 480 | let checks = [if ((periodUserAvailableToClaim > 0)) | |
481 | 481 | then true | |
482 | 482 | else throwErr("unavailable to claim because user period allowance reached"), if ((periodTotalAvailableToClaim > 0)) | |
483 | 483 | then true | |
484 | 484 | else throwErr("unavailable to claim because total period allowance reached"), if ((periodMinAvailableToClaim > 0)) | |
485 | 485 | then true | |
486 | 486 | else throwErr("nothing to claim"), if ((usdtPriceAssetAllowableRatio > currentUsdtPriceAssetRatio)) | |
487 | 487 | then true | |
488 | 488 | else throwErr("unavailable to claim because usdn price lower than usdtPriceAssetAllowableRatio")] | |
489 | 489 | if ((checks == checks)) | |
490 | 490 | then { | |
491 | 491 | let updatedPeriodTotalAvailableToClaim = (periodTotalAvailableToClaim - periodMinAvailableToClaim) | |
492 | 492 | let updatedPeriodUserAvailableToClaim = (periodUserAvailableToClaim - periodMinAvailableToClaim) | |
493 | 493 | let entries = if ((priceAssetBalance > periodMinAvailableToClaim)) | |
494 | 494 | then [ScriptTransfer(i.caller, periodMinAvailableToClaim, outAssetId), IntegerEntry(keyPriceAssetBalance(userAddress58), (priceAssetBalance - periodMinAvailableToClaim))] | |
495 | 495 | else { | |
496 | 496 | let evaluateResult = split(asString(invoke(this, "claimREADONLY", [priceAssetId58, userAddress58], nil)), SEP) | |
497 | 497 | if ((evaluateResult == evaluateResult)) | |
498 | 498 | then { | |
499 | 499 | let availablePriceAmountToClaim = parseIntValue(evaluateResult[3]) | |
500 | 500 | let lastClaimEntries = if ((availablePriceAmountToClaim == periodMinAvailableToClaim)) | |
501 | 501 | then { | |
502 | 502 | let investorTotalAmount = parseIntValue(origInvestArray[IdxInvTotalAmount]) | |
503 | 503 | let investorRemainingAmount = parseIntValue(origInvestArray[IdxInvRemainingAmount]) | |
504 | 504 | let investorPriceAssetBalance = parseIntValue(origInvestArray[IdxInvClaimedPriceAssetAmount]) | |
505 | 505 | let investorIdoAssetBalance = parseIntValue(origInvestArray[IdxInvClaimedIdoAssetAmount]) | |
506 | 506 | let investorLastClaimedHeight = parseIntValue(origInvestArray[IdxInvLastClaimedHeight]) | |
507 | 507 | let newInvestArray = [toString(investorTotalAmount), "0", toString(investorPriceAssetBalance), toString(investorIdoAssetBalance), toString(investorLastClaimedHeight)] | |
508 | 508 | let totals = readTotalsArrayOrDefault() | |
509 | 509 | let totalsTotalAmount = parseIntValue(totals[IdxInvTotalAmount]) | |
510 | 510 | let totalsRemainingAmount = parseIntValue(totals[IdxInvRemainingAmount]) | |
511 | 511 | let totalsClaimedPriceAssetAmount = parseIntValue(totals[IdxInvRemainingAmount]) | |
512 | 512 | let totalsClaimedIdoAssetAmount = parseIntValue(totals[IdxInvClaimedPriceAssetAmount]) | |
513 | 513 | let totalsLastClaimedHeight = parseIntValue(totals[IdxInvLastClaimedHeight]) | |
514 | 514 | let newTotalsRemainingAmount = (totalsRemainingAmount - investorRemainingAmount) | |
515 | 515 | let newTotalArray = [toString(totalsTotalAmount), toString(newTotalsRemainingAmount), toString(totalsClaimedPriceAssetAmount), toString(totalsClaimedIdoAssetAmount), toString(totalsLastClaimedHeight)] | |
516 | 516 | let newTotalRemainingAmount = (valueOrElse(getInteger(keyTotalRemainingAmount()), 0) + investorRemainingAmount) | |
517 | 517 | [StringEntry(keyInvestorRemainingAmount(userAddress58), toString(investorRemainingAmount)), StringEntry(keyTotalRemainingAmount(), toString(newTotalRemainingAmount)), TotalsEntry(keyInvestor(userAddress58), newInvestArray, totalsDiff, newClaimPeriodHeight, 0), TotalsEntry(keyTotals(), newTotalArray, totalsDiff, newClaimPeriodHeight, 0)] | |
518 | 518 | } | |
519 | 519 | else [TotalsEntry(keyInvestor(userAddress58), origInvestArray, totalsDiff, newClaimPeriodHeight, 0), TotalsEntry(keyTotals(), readTotalsArrayOrDefault(), totalsDiff, newClaimPeriodHeight, 0)] | |
520 | 520 | let updatedPriceAssetBalance = ((priceAssetBalance + outAmount) - periodMinAvailableToClaim) | |
521 | 521 | ([ScriptTransfer(i.caller, periodMinAvailableToClaim, outAssetId), IntegerEntry(keyPriceAssetBalance(userAddress58), updatedPriceAssetBalance)] ++ lastClaimEntries) | |
522 | 522 | } | |
523 | 523 | else throw("Strict value is not equal to itself.") | |
524 | 524 | } | |
525 | 525 | $Tuple2(([IntegerEntry(keyCurrentPeriod(), updatedCurrentPeriod), IntegerEntry(keyPeriodStartHeight(updatedCurrentPeriod), periodStart), IntegerEntry(keyPeriodEndHeight(updatedCurrentPeriod), periodEnd), IntegerEntry(keyPeriodTotalAvailableToClaim(priceAssetId58, updatedCurrentPeriod), updatedPeriodTotalAvailableToClaim), IntegerEntry(keyPeriodUserAvailableToClaim(priceAssetId58, updatedCurrentPeriod, userAddress58), updatedPeriodUserAvailableToClaim), ClaimOperationHistoryEntry(userAddress58, periodMinAvailableToClaim, claimedIdoAssetAmountFromDiff, i.transactionId)] ++ entries), unit) | |
526 | 526 | } | |
527 | 527 | else throw("Strict value is not equal to itself.") | |
528 | 528 | } | |
529 | 529 | else { | |
530 | 530 | let priceAssetBalanceIdoDecimals = fraction(priceAssetBalance, scale8, pow(10, 0, priceAssetDecimals, 0, 0, DOWN)) | |
531 | 531 | $Tuple2([ScriptTransfer(i.caller, (outAmount + priceAssetBalanceIdoDecimals), outAssetId), IntegerEntry(keyPriceAssetBalance(userAddress58), 0), TotalsEntry(keyInvestor(userAddress58), origInvestArray, totalsDiff, newClaimPeriodHeight, priceAssetBalance), TotalsEntry(keyTotals(), readTotalsArrayOrDefault(), totalsDiff, newClaimPeriodHeight, priceAssetBalance), ClaimOperationHistoryEntry(userAddress58, claimedPriceAmountFromDiff, (claimedIdoAssetAmountFromDiff + priceAssetBalanceIdoDecimals), i.transactionId)], unit) | |
532 | 532 | } | |
533 | 533 | entries | |
534 | 534 | } | |
535 | 535 | } | |
536 | 536 | ||
537 | 537 | ||
538 | 538 | ||
539 | 539 | @Callable(i) | |
540 | 540 | func cleanRemaingAmount (userAddress58) = { | |
541 | 541 | let priceAssetId58 = readConfigArray()[IdxCfgPriceAssetId] | |
542 | 542 | let evaluateResult = split(asString(invoke(this, "claimREADONLY", [priceAssetId58, userAddress58], nil)), SEP) | |
543 | 543 | if ((evaluateResult == evaluateResult)) | |
544 | 544 | then { | |
545 | - | let availablePriceAmountToClaim = parseIntValue(evaluateResult[ | |
545 | + | let availablePriceAmountToClaim = parseIntValue(evaluateResult[2]) | |
546 | 546 | let checkUnclaimedAssets = if ((availablePriceAmountToClaim == 0)) | |
547 | 547 | then true | |
548 | 548 | else throwErr("user have unclaimed assets") | |
549 | 549 | if ((checkUnclaimedAssets == checkUnclaimedAssets)) | |
550 | 550 | then { | |
551 | 551 | let investor = split(value(getString(keyInvestor(userAddress58))), SEP) | |
552 | 552 | let investorTotalAmount = parseIntValue(investor[IdxInvTotalAmount]) | |
553 | 553 | let investorRemainingAmount = parseIntValue(investor[IdxInvRemainingAmount]) | |
554 | 554 | let investorPriceAssetBalance = parseIntValue(investor[IdxInvClaimedPriceAssetAmount]) | |
555 | 555 | let investorIdoAssetBalance = parseIntValue(investor[IdxInvClaimedIdoAssetAmount]) | |
556 | 556 | let investorLastClaimedHeight = parseIntValue(investor[IdxInvLastClaimedHeight]) | |
557 | 557 | let investorRemainingAmountCheck = if ((investorRemainingAmount != 0)) | |
558 | 558 | then true | |
559 | 559 | else throwErr("investorRemainingAmount already zero") | |
560 | 560 | if ((investorRemainingAmountCheck == investorRemainingAmountCheck)) | |
561 | 561 | then { | |
562 | 562 | let newInvestor = makeString(["%d%d%d%d%d", toString(investorTotalAmount), "0", toString(investorPriceAssetBalance), toString(investorIdoAssetBalance), toString(investorLastClaimedHeight)], SEP) | |
563 | 563 | let totals = split(value(getString(keyTotals())), SEP) | |
564 | 564 | let totalsTotalAmount = parseIntValue(totals[IdxInvTotalAmount]) | |
565 | 565 | let totalsRemainingAmount = parseIntValue(totals[IdxInvRemainingAmount]) | |
566 | - | let totalsClaimedPriceAssetAmount = parseIntValue(totals[ | |
567 | - | let totalsClaimedIdoAssetAmount = parseIntValue(totals[ | |
566 | + | let totalsClaimedPriceAssetAmount = parseIntValue(totals[IdxInvClaimedPriceAssetAmount]) | |
567 | + | let totalsClaimedIdoAssetAmount = parseIntValue(totals[IdxInvClaimedIdoAssetAmount]) | |
568 | 568 | let totalsLastClaimedHeight = parseIntValue(totals[IdxInvLastClaimedHeight]) | |
569 | 569 | let newTotals = makeString(["%d%d%d%d%d", toString(totalsTotalAmount), toString((totalsRemainingAmount - investorRemainingAmount)), toString(totalsClaimedPriceAssetAmount), toString(totalsClaimedIdoAssetAmount), toString(totalsLastClaimedHeight)], SEP) | |
570 | 570 | let newTotalRemainingAmount = (valueOrElse(getInteger(keyTotalRemainingAmount()), 0) + investorRemainingAmount) | |
571 | 571 | [StringEntry(keyInvestorRemainingAmount(userAddress58), toString(investorRemainingAmount)), StringEntry(keyTotalRemainingAmount(), toString(newTotalRemainingAmount)), StringEntry(keyInvestor(userAddress58), newInvestor), StringEntry(keyTotals(), newTotals)] | |
572 | 572 | } | |
573 | 573 | else throw("Strict value is not equal to itself.") | |
574 | 574 | } | |
575 | 575 | else throw("Strict value is not equal to itself.") | |
576 | 576 | } | |
577 | 577 | else throw("Strict value is not equal to itself.") | |
578 | 578 | } | |
579 | 579 | ||
580 | 580 | ||
581 | 581 | ||
582 | 582 | @Callable(i) | |
583 | 583 | func claimREADONLY (claimedAssetId58,userAddress58) = { | |
584 | 584 | let claimResultTuple = internalClaim(claimedAssetId58, addressFromStringValue(userAddress58), fromBase58String("")) | |
585 | 585 | let totalsDiff = claimResultTuple._1 | |
586 | 586 | let outAmount = claimResultTuple._2 | |
587 | 587 | let outAssetId = claimResultTuple._3 | |
588 | 588 | let origInvestArray = claimResultTuple._4 | |
589 | 589 | let newClaimPeriodHeight = claimResultTuple._5 | |
590 | 590 | let availableToClaimArray = claimResultTuple._6 | |
591 | 591 | let availablePriceAmountToClaim = availableToClaimArray[0] | |
592 | 592 | let availableIdoAmountToClaim = availableToClaimArray[1] | |
593 | 593 | $Tuple2(nil, makeString(["%s%d%d", userAddress58, toString(availablePriceAmountToClaim), toString(availableIdoAmountToClaim)], SEP)) | |
594 | 594 | } | |
595 | 595 | ||
596 | 596 | ||
597 | 597 | ||
598 | 598 | @Callable(i) | |
599 | 599 | func claimV2READONLY (claimedAssetId58,userAddress58) = { | |
600 | 600 | let claimResultTuple = internalClaim(claimedAssetId58, addressFromStringValue(userAddress58), fromBase58String("")) | |
601 | 601 | let totalsDiff = claimResultTuple._1 | |
602 | 602 | let outAmount = claimResultTuple._2 | |
603 | 603 | let outAssetId = claimResultTuple._3 | |
604 | 604 | let origInvestArray = claimResultTuple._4 | |
605 | 605 | let newClaimPeriodHeight = claimResultTuple._5 | |
606 | 606 | let availableToClaimArray = claimResultTuple._6 | |
607 | 607 | let availablePriceAmountToClaim = availableToClaimArray[0] | |
608 | 608 | let availableIdoAmountToClaim = availableToClaimArray[1] | |
609 | 609 | let cfgArray = readConfigArray() | |
610 | 610 | let priceAssetId58 = cfgArray[IdxCfgPriceAssetId] | |
611 | 611 | let priceAssetBalance = valueOrElse(getInteger(keyPriceAssetBalance(userAddress58)), 0) | |
612 | 612 | let priceAssetBalanceIdoDecimals = (priceAssetBalance * 100) | |
613 | 613 | let availableIdoAmountToClaimWithPriceAssetBalance = (availableIdoAmountToClaim + priceAssetBalanceIdoDecimals) | |
614 | - | let $ | |
615 | - | let periodMinAvailableToClaim = $ | |
616 | - | let periodTotalAvailableToClaim = $ | |
617 | - | let periodUserAvailableToClaim = $ | |
618 | - | let totalUserAvailableToClaim = $ | |
619 | - | let usdtPriceAssetAllowableRatio = $ | |
620 | - | let currentUsdtPriceAssetRatio = $ | |
621 | - | let endPeriodBlocksLeft = $ | |
622 | - | let updatedCurrentPeriod = $ | |
623 | - | let periodStart = $ | |
624 | - | let periodEnd = $ | |
614 | + | let $t03374334155 = internalClaimV2(priceAssetId58, userAddress58, outAmount, totalsDiff[IdxDiffClaimedPriceAmountIncrement]) | |
615 | + | let periodMinAvailableToClaim = $t03374334155._1 | |
616 | + | let periodTotalAvailableToClaim = $t03374334155._2 | |
617 | + | let periodUserAvailableToClaim = $t03374334155._3 | |
618 | + | let totalUserAvailableToClaim = $t03374334155._4 | |
619 | + | let usdtPriceAssetAllowableRatio = $t03374334155._5 | |
620 | + | let currentUsdtPriceAssetRatio = $t03374334155._6 | |
621 | + | let endPeriodBlocksLeft = $t03374334155._7 | |
622 | + | let updatedCurrentPeriod = $t03374334155._8 | |
623 | + | let periodStart = $t03374334155._9 | |
624 | + | let periodEnd = $t03374334155._10 | |
625 | 625 | let currentPeriodEndHeight = valueOrElse(getInteger(keyPeriodEndHeight(updatedCurrentPeriod)), 0) | |
626 | 626 | let userTotalPriceAssetClaimed = (parseIntValue(readInvestorArrayOrFail(userAddress58)[IdxInvClaimedPriceAssetAmount]) - priceAssetBalance) | |
627 | 627 | let resultString = if ((height > currentPeriodEndHeight)) | |
628 | 628 | then { | |
629 | 629 | let periodLenght = value(getInteger(keyPeriodLength())) | |
630 | 630 | let userPeriodAllowance = value(getInteger(keyUserPeriodAllowance(priceAssetId58))) | |
631 | 631 | let totalPeriodAllowance = value(getInteger(keyTotalPeriodAllowance(priceAssetId58))) | |
632 | 632 | makeString(["%d%d%d%d%d%d", toString(availableIdoAmountToClaimWithPriceAssetBalance), toString(userPeriodAllowance), toString(totalPeriodAllowance), toString(usdtPriceAssetAllowableRatio), toString(currentUsdtPriceAssetRatio), toString(periodLenght), toString(userTotalPriceAssetClaimed)], SEP) | |
633 | 633 | } | |
634 | 634 | else makeString(["%d%d%d%d%d%d", toString(availableIdoAmountToClaimWithPriceAssetBalance), toString(periodMinAvailableToClaim), toString(periodTotalAvailableToClaim), toString(usdtPriceAssetAllowableRatio), toString(currentUsdtPriceAssetRatio), toString(endPeriodBlocksLeft), toString(userTotalPriceAssetClaimed)], SEP) | |
635 | 635 | $Tuple2(nil, resultString) | |
636 | 636 | } | |
637 | 637 | ||
638 | 638 | ||
639 | 639 | ||
640 | 640 | @Callable(i) | |
641 | 641 | func setManager (pendingManagerPublicKey) = { | |
642 | 642 | let checkCaller = mustManager(i) | |
643 | 643 | if ((checkCaller == checkCaller)) | |
644 | 644 | then { | |
645 | 645 | let checkManagerPublicKey = fromBase58String(pendingManagerPublicKey) | |
646 | 646 | if ((checkManagerPublicKey == checkManagerPublicKey)) | |
647 | 647 | then [StringEntry(keyPendingManagerPublicKey(), pendingManagerPublicKey)] | |
648 | 648 | else throw("Strict value is not equal to itself.") | |
649 | 649 | } | |
650 | 650 | else throw("Strict value is not equal to itself.") | |
651 | 651 | } | |
652 | 652 | ||
653 | 653 | ||
654 | 654 | ||
655 | 655 | @Callable(i) | |
656 | 656 | func confirmManager () = { | |
657 | 657 | let pm = pendingManagerPublicKeyOrUnit() | |
658 | 658 | let hasPM = if (isDefined(pm)) | |
659 | 659 | then true | |
660 | 660 | else throw("No pending manager") | |
661 | 661 | if ((hasPM == hasPM)) | |
662 | 662 | then { | |
663 | 663 | let checkPM = if ((i.callerPublicKey == value(pm))) | |
664 | 664 | then true | |
665 | 665 | else throw("You are not pending manager") | |
666 | 666 | if ((checkPM == checkPM)) | |
667 | 667 | then [StringEntry(keyManagerPublicKey(), toBase58String(value(pm))), DeleteEntry(keyPendingManagerPublicKey())] | |
668 | 668 | else throw("Strict value is not equal to itself.") | |
669 | 669 | } | |
670 | 670 | else throw("Strict value is not equal to itself.") | |
671 | 671 | } | |
672 | 672 | ||
673 | 673 | ||
674 | 674 | @Verifier(tx) | |
675 | 675 | func verify () = { | |
676 | 676 | let targetPublicKey = match managerPublicKeyOrUnit() { | |
677 | 677 | case pk: ByteVector => | |
678 | 678 | pk | |
679 | 679 | case _: Unit => | |
680 | 680 | tx.senderPublicKey | |
681 | 681 | case _ => | |
682 | 682 | throw("Match error") | |
683 | 683 | } | |
684 | 684 | sigVerify(tx.bodyBytes, tx.proofs[0], targetPublicKey) | |
685 | 685 | } | |
686 | 686 |
github/deemru/w8io/026f985 73.86 ms ◑