tx · 5xq9qEvy4K3X5NYZ8UX4YX8ppCFKLJj6JxmyZWWaLD5z 3Mzfii66XizWNVN6DYuKJhaNxbpNT7e8QoP: -0.01000000 Waves 2020.06.16 11:30 [1045805] smart account 3Mzfii66XizWNVN6DYuKJhaNxbpNT7e8QoP > SELF 0.00000000 Waves
{ "type": 13, "id": "5xq9qEvy4K3X5NYZ8UX4YX8ppCFKLJj6JxmyZWWaLD5z", "fee": 1000000, "feeAssetId": null, "timestamp": 1592296244388, "version": 1, "sender": "3Mzfii66XizWNVN6DYuKJhaNxbpNT7e8QoP", "senderPublicKey": "2UawJjyqBUmVjeUy3Su5xWoeWhQWmLZqy2PQovMHDhuQ", "proofs": [ "4Je7ExJyGbeiMqiWbFjbazcFKLS7R1UzhjrXnzpwu3EQjvjH4Xg2bJkDtPQUKnSvi3wn9e8itPEeSqtsckvpW8Wd" ], "script": "base64:AAIDAAAAAAAAAAsIARIAEgASAwoBCAAAADgAAAAAC3BhcmFtUHJlZml4AgAAAAZwYXJhbV8AAAAAC2FkZHJlc3NCb29rCQEAAAAHQWRkcmVzcwAAAAEBAAAAGgFUVoHUeTQTO77iaMaO0CyN+LlydsBXbwHeAAAAABN3aGl0ZWxpc3RBZGRyZXNzS2V5AgAAABB3aGl0ZWxpc3RBZGRyZXNzAAAAABdkQXBwV2hpdGVsaXN0QWRkcmVzc0tleQIAAAAUZEFwcFdoaXRlbGlzdEFkZHJlc3MAAAAAFGV4dHJhY3RlZEFkZHJlc3NCb29rCQEAAAAHZXh0cmFjdAAAAAEFAAAAC2FkZHJlc3NCb29rAQAAAA5nZXRTdHJpbmdQYXJhbQAAAAEAAAADa2V5BAAAAAckbWF0Y2gwCQAEHQAAAAIFAAAABHRoaXMJAAEsAAAAAgUAAAALcGFyYW1QcmVmaXgFAAAAA2tleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAGU3RyaW5nBAAAAAFhBQAAAAckbWF0Y2gwBQAAAAFhCQAAAgAAAAECAAAADW5vIHN0c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kABBoAAAACBQAAAAlwQWRkcmVzczcFAAAABHR4SWQAAAAAAAAAAAEAAAAAAAAAAAAEAAAAC3BLZXk4U2lnbmVkAwkBAAAACWlzRGVmaW5lZAAAAAEJAAQaAAAAAgUAAAAJcEFkZHJlc3M4BQAAAAR0eElkAAAAAAAAAAABAAAAAAAAAAAACQAAZwAAAAIJAABkAAAAAgkAAGQAAAACCQAAZAAAAAIJAABkAAAAAgkAAGQAAAACCQAAZAAAAAIJAABkAAAAAgUAAAALcEtleTFTaWduZWQFAAAAC3BLZXkyU2lnbmVkBQAAAAtwS2V5M1NpZ25lZAUAAAALcEtleTRTaWduZWQFAAAAC3BLZXk1U2lnbmVkBQAAAAtwS2V5NlNpZ25lZAUAAAALcEtleTdTaWduZWQFAAAAC3BLZXk4U2lnbmVkAAAAAAAAAAADBwsIg2w=", "chainId": 84, "height": 1045805, "spentComplexity": 0 } View: original | compacted Prev: none Next: none Full:
Old | New | Differences | |
---|---|---|---|
1 | - | # no script | |
1 | + | {-# STDLIB_VERSION 3 #-} | |
2 | + | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | + | {-# CONTENT_TYPE DAPP #-} | |
4 | + | let paramPrefix = "param_" | |
5 | + | ||
6 | + | let addressBook = Address(base58'3MwoVRAPfC2NKuuYJKHVAVtUFhq8MyTEfQh') | |
7 | + | ||
8 | + | let whitelistAddressKey = "whitelistAddress" | |
9 | + | ||
10 | + | let dAppWhitelistAddressKey = "dAppWhitelistAddress" | |
11 | + | ||
12 | + | let extractedAddressBook = extract(addressBook) | |
13 | + | ||
14 | + | func getStringParam (key) = match getString(this, (paramPrefix + key)) { | |
15 | + | case a: String => | |
16 | + | a | |
17 | + | case _ => | |
18 | + | throw("no string key") | |
19 | + | } | |
20 | + | ||
21 | + | ||
22 | + | func getIntParam (key) = match getInteger(this, (paramPrefix + key)) { | |
23 | + | case a: Int => | |
24 | + | a | |
25 | + | case _ => | |
26 | + | throw("no int key") | |
27 | + | } | |
28 | + | ||
29 | + | ||
30 | + | func getBooleanParam (key) = match getBoolean(this, (paramPrefix + key)) { | |
31 | + | case a: Boolean => | |
32 | + | a | |
33 | + | case _ => | |
34 | + | throw("no boolean key") | |
35 | + | } | |
36 | + | ||
37 | + | ||
38 | + | let issuerAssetId = base58'iHwcthhUctXb72onKyqh1J5TdUeAeDs2YRcpCbQFjx6' | |
39 | + | ||
40 | + | let investmentAssetId = base58'Emn8cyGDFgnLCKLTXqVWhKJARhtR2muBUuZaSmqNzDfn' | |
41 | + | ||
42 | + | let investmentAssetIdIsWaves = false | |
43 | + | ||
44 | + | let ownerAddressString = getStringParam("issuerAccountAddress") | |
45 | + | ||
46 | + | let ownerAddress = extract(addressFromString(ownerAddressString)) | |
47 | + | ||
48 | + | let assetDecimalsOffset = 1 | |
49 | + | ||
50 | + | let tokensaleAmount = getIntParam("tokensaleAmount") | |
51 | + | ||
52 | + | let startTime = getIntParam("startTime") | |
53 | + | ||
54 | + | let endTime = getIntParam("endTime") | |
55 | + | ||
56 | + | let price = getIntParam("price") | |
57 | + | ||
58 | + | let softCapAmount = getIntParam("softCapAmount") | |
59 | + | ||
60 | + | let minPayment = getIntParam("minPayment") | |
61 | + | ||
62 | + | let swapAssetId = base58'' | |
63 | + | ||
64 | + | let swapAmount = getIntParam("swapAmount") | |
65 | + | ||
66 | + | let swapPrice = getIntParam("swapPrice") | |
67 | + | ||
68 | + | let companyType = 0 | |
69 | + | ||
70 | + | let isTokensale = 0 | |
71 | + | ||
72 | + | let isSwap = 1 | |
73 | + | ||
74 | + | let isTokensaleAndSwap = 2 | |
75 | + | ||
76 | + | let swapKeySumAmountPrefix = "swapSumAmount " | |
77 | + | ||
78 | + | let swapKeySumAssetsPrefix = "swapSumAssets " | |
79 | + | ||
80 | + | let swapKeyDistAssets = "swapAssets" | |
81 | + | ||
82 | + | let swapKeyCollectedAmount = "swapAmount" | |
83 | + | ||
84 | + | let keySumAmountPrefix = "sumAmount " | |
85 | + | ||
86 | + | let keySumPaidAmountPrefix = "paidAmount " | |
87 | + | ||
88 | + | let keySumAssetsPrefix = "sumAssets " | |
89 | + | ||
90 | + | let keyAllowAccountPrefix = "allow " | |
91 | + | ||
92 | + | let keyDistAssets = "assets" | |
93 | + | ||
94 | + | let keyCollectedAmount = "amount" | |
95 | + | ||
96 | + | let keyIssuer = "issuer" | |
97 | + | ||
98 | + | let ver = "5.0.1" | |
99 | + | ||
100 | + | let validState = 1000 | |
101 | + | ||
102 | + | func getAddressFromBook (key) = match getString(addressBook, key) { | |
103 | + | case a: String => | |
104 | + | Address(fromBase58String(a)) | |
105 | + | case _ => | |
106 | + | throw("no key") | |
107 | + | } | |
108 | + | ||
109 | + | ||
110 | + | let whitelistAddress = getAddressFromBook(whitelistAddressKey) | |
111 | + | ||
112 | + | let dAppWhitelistAddress = getAddressFromBook(dAppWhitelistAddressKey) | |
113 | + | ||
114 | + | func isTokensaleAllow () = if ((companyType == isTokensale)) | |
115 | + | then true | |
116 | + | else (companyType == isTokensaleAndSwap) | |
117 | + | ||
118 | + | ||
119 | + | func isSwapAllow () = if ((companyType == isSwap)) | |
120 | + | then true | |
121 | + | else (companyType == isTokensaleAndSwap) | |
122 | + | ||
123 | + | ||
124 | + | func getCurrentTime () = { | |
125 | + | let blockInfo = value(blockInfoByHeight(height)) | |
126 | + | (blockInfo.timestamp / 1000) | |
127 | + | } | |
128 | + | ||
129 | + | ||
130 | + | func getInvestmentAssetIdForTransfer (isWaves,assetId) = if ((isWaves == false)) | |
131 | + | then assetId | |
132 | + | else unit | |
133 | + | ||
134 | + | ||
135 | + | func getCurrentPrice () = price | |
136 | + | ||
137 | + | ||
138 | + | func getAmount (key) = match getInteger(this, key) { | |
139 | + | case a: Int => | |
140 | + | a | |
141 | + | case _ => | |
142 | + | 0 | |
143 | + | } | |
144 | + | ||
145 | + | ||
146 | + | func hasStarted () = (getCurrentTime() >= startTime) | |
147 | + | ||
148 | + | ||
149 | + | func tokensaleHasEnded () = { | |
150 | + | let assets = match getInteger(this, keyDistAssets) { | |
151 | + | case a: Int => | |
152 | + | a | |
153 | + | case _ => | |
154 | + | tokensaleAmount | |
155 | + | } | |
156 | + | if ((getCurrentTime() > endTime)) | |
157 | + | then true | |
158 | + | else (assets == 0) | |
159 | + | } | |
160 | + | ||
161 | + | ||
162 | + | func swapHasEnded () = { | |
163 | + | let assets = match getInteger(this, swapKeyDistAssets) { | |
164 | + | case a: Int => | |
165 | + | a | |
166 | + | case _ => | |
167 | + | swapAmount | |
168 | + | } | |
169 | + | if ((getCurrentTime() > endTime)) | |
170 | + | then true | |
171 | + | else (assets == 0) | |
172 | + | } | |
173 | + | ||
174 | + | ||
175 | + | func companyHasEnded () = if (if (isSwapAllow()) | |
176 | + | then isTokensaleAllow() | |
177 | + | else false) | |
178 | + | then if (tokensaleHasEnded()) | |
179 | + | then swapHasEnded() | |
180 | + | else false | |
181 | + | else if (isTokensaleAllow()) | |
182 | + | then tokensaleHasEnded() | |
183 | + | else if (isSwapAllow()) | |
184 | + | then swapHasEnded() | |
185 | + | else false | |
186 | + | ||
187 | + | ||
188 | + | func getPayment (i) = match i.payment { | |
189 | + | case p: AttachedPayment => | |
190 | + | let isPaymentOk = match p.assetId { | |
191 | + | case assetId: ByteVector => | |
192 | + | if (!(investmentAssetIdIsWaves)) | |
193 | + | then (assetId == investmentAssetId) | |
194 | + | else false | |
195 | + | case _ => | |
196 | + | (investmentAssetIdIsWaves == true) | |
197 | + | } | |
198 | + | if (isPaymentOk) | |
199 | + | then if ((assetDecimalsOffset == 1)) | |
200 | + | then if (((p.amount % price) == 0)) | |
201 | + | then p.amount | |
202 | + | else throw("#0300 payment amount must be a multiple of token price") | |
203 | + | else p.amount | |
204 | + | else throw("#0200 Invalid asset ID of investment") | |
205 | + | case _ => | |
206 | + | throw("#0100 Payment must be attached") | |
207 | + | } | |
208 | + | ||
209 | + | ||
210 | + | func getSwapPayment (i) = match i.payment { | |
211 | + | case p: AttachedPayment => | |
212 | + | let isPaymentOk = match p.assetId { | |
213 | + | case assetId: ByteVector => | |
214 | + | (assetId == swapAssetId) | |
215 | + | case _ => | |
216 | + | false | |
217 | + | } | |
218 | + | if (isPaymentOk) | |
219 | + | then if ((assetDecimalsOffset == 1)) | |
220 | + | then if (((p.amount % swapPrice) == 0)) | |
221 | + | then p.amount | |
222 | + | else throw("payment amount must be a multiple of token price") | |
223 | + | else p.amount | |
224 | + | else throw("Invalid asset ID of investment") | |
225 | + | case _ => | |
226 | + | throw("Payment must be attached") | |
227 | + | } | |
228 | + | ||
229 | + | ||
230 | + | func getInvestorAddressForWithdrawal (argAddress,callerAddress) = if ((size(argAddress) > 10)) | |
231 | + | then argAddress | |
232 | + | else callerAddress | |
233 | + | ||
234 | + | ||
235 | + | @Callable(i) | |
236 | + | func deposit () = { | |
237 | + | let currentPrice = getCurrentPrice() | |
238 | + | let accountAmount = getAmount(keyCollectedAmount) | |
239 | + | let dAppStatus = match getInteger(dAppWhitelistAddress, toString(this)) { | |
240 | + | case a: Int => | |
241 | + | a | |
242 | + | case _ => | |
243 | + | -1000 | |
244 | + | } | |
245 | + | if (!(isTokensaleAllow())) | |
246 | + | then throw("#1000 This deposit method is unsopperted for this company") | |
247 | + | else if (!(hasStarted())) | |
248 | + | then throw(((("#0001 The Tokensale works between " + toString(startTime)) + " and ") + toString(endTime))) | |
249 | + | else if (tokensaleHasEnded()) | |
250 | + | then throw("#0002 The required amount has already been accumulated. If you are an investor, you can withdraw your funds.") | |
251 | + | else if ((dAppStatus == -1000)) | |
252 | + | then throw("#0010 This company is unsopperted") | |
253 | + | else { | |
254 | + | let payment = getPayment(i) | |
255 | + | let currentKey = toBase58String(i.caller.bytes) | |
256 | + | let isAccountAllow = match getInteger(whitelistAddress, currentKey) { | |
257 | + | case a: Int => | |
258 | + | a | |
259 | + | case _ => | |
260 | + | -255 | |
261 | + | } | |
262 | + | if ((currentKey == ownerAddressString)) | |
263 | + | then throw("#0030 The issuer can`t invest in its own company") | |
264 | + | else if ((validState > isAccountAllow)) | |
265 | + | then throw(((("#0020 Your account has no right to send funds. _ " + currentKey) + " ") + ownerAddressString)) | |
266 | + | else { | |
267 | + | let accountAssets = match getInteger(this, keyDistAssets) { | |
268 | + | case a: Int => | |
269 | + | a | |
270 | + | case _ => | |
271 | + | tokensaleAmount | |
272 | + | } | |
273 | + | let tokensCalc = fraction(payment, assetDecimalsOffset, currentPrice) | |
274 | + | let minPaymentInAssets = fraction(minPayment, assetDecimalsOffset, currentPrice) | |
275 | + | if (if (if ((0 > (accountAssets - tokensCalc))) | |
276 | + | then true | |
277 | + | else (minPaymentInAssets > tokensCalc)) | |
278 | + | then true | |
279 | + | else if ((tokensCalc != accountAssets)) | |
280 | + | then (tokensCalc > (accountAssets - minPaymentInAssets)) | |
281 | + | else false) | |
282 | + | then throw("#0400 Incorrect payment amount.") | |
283 | + | else { | |
284 | + | let newInvestorAmount = (getAmount((keySumAmountPrefix + currentKey)) + payment) | |
285 | + | let newInvestorAssets = (getAmount((keySumAssetsPrefix + currentKey)) + tokensCalc) | |
286 | + | let newAccountAssets = (accountAssets - tokensCalc) | |
287 | + | let newAccountAmount = (accountAmount + payment) | |
288 | + | WriteSet([DataEntry((keySumAmountPrefix + currentKey), newInvestorAmount), DataEntry((keySumAssetsPrefix + currentKey), newInvestorAssets), DataEntry(keyDistAssets, newAccountAssets), DataEntry(keyCollectedAmount, newAccountAmount)]) | |
289 | + | } | |
290 | + | } | |
291 | + | } | |
292 | + | } | |
293 | + | ||
294 | + | ||
295 | + | ||
296 | + | @Callable(i) | |
297 | + | func swapDeposit () = { | |
298 | + | let currentPrice = swapPrice | |
299 | + | let accountAmount = getAmount(swapKeyCollectedAmount) | |
300 | + | let dAppStatus = match getInteger(dAppWhitelistAddress, toString(this)) { | |
301 | + | case a: Int => | |
302 | + | a | |
303 | + | case _ => | |
304 | + | -1000 | |
305 | + | } | |
306 | + | if (!(isSwapAllow())) | |
307 | + | then throw("#2000 This swap-deposit method is unsopperted for this company") | |
308 | + | else if (!(hasStarted())) | |
309 | + | then throw(((("The Tokensale works between " + toString(startTime)) + " and ") + toString(endTime))) | |
310 | + | else if (swapHasEnded()) | |
311 | + | then throw("The required amount has already been accumulated. If you are an investor, you can withdraw your funds.") | |
312 | + | else if ((dAppStatus == -1000)) | |
313 | + | then throw("#0010 This company is unsupported") | |
314 | + | else { | |
315 | + | let payment = getSwapPayment(i) | |
316 | + | let currentKey = toBase58String(i.caller.bytes) | |
317 | + | let isAccountAllow = match getInteger(whitelistAddress, currentKey) { | |
318 | + | case a: Int => | |
319 | + | a | |
320 | + | case _ => | |
321 | + | -255 | |
322 | + | } | |
323 | + | if ((validState > isAccountAllow)) | |
324 | + | then throw("#0020 Your account has no right to send funds.") | |
325 | + | else { | |
326 | + | let accountAssets = match getInteger(this, swapKeyDistAssets) { | |
327 | + | case a: Int => | |
328 | + | a | |
329 | + | case _ => | |
330 | + | swapAmount | |
331 | + | } | |
332 | + | let tokensCalc = fraction(payment, assetDecimalsOffset, currentPrice) | |
333 | + | if ((0 > (accountAssets - tokensCalc))) | |
334 | + | then throw("Incorrect payment amount.") | |
335 | + | else { | |
336 | + | let newInvestorAmount = (getAmount((swapKeySumAmountPrefix + currentKey)) + payment) | |
337 | + | let newInvestorAssets = (getAmount((swapKeySumAssetsPrefix + currentKey)) + tokensCalc) | |
338 | + | let newAccountAssets = (accountAssets - tokensCalc) | |
339 | + | let newAccountAmount = (accountAmount + payment) | |
340 | + | WriteSet([DataEntry((swapKeySumAmountPrefix + currentKey), newInvestorAmount), DataEntry((swapKeySumAssetsPrefix + currentKey), newInvestorAssets), DataEntry(swapKeyDistAssets, newAccountAssets), DataEntry(swapKeyCollectedAmount, newAccountAmount)]) | |
341 | + | } | |
342 | + | } | |
343 | + | } | |
344 | + | } | |
345 | + | ||
346 | + | ||
347 | + | ||
348 | + | @Callable(i) | |
349 | + | func withdrawal (address) = { | |
350 | + | let dAppStatus = match getInteger(dAppWhitelistAddress, toString(this)) { | |
351 | + | case a: Int => | |
352 | + | a | |
353 | + | case _ => | |
354 | + | 0 | |
355 | + | } | |
356 | + | if ((dAppStatus == 0)) | |
357 | + | then throw("#0030 Withdrawals are not available until the issuer passes verification") | |
358 | + | else { | |
359 | + | let currentKey = getInvestorAddressForWithdrawal(address, toBase58String(i.caller.bytes)) | |
360 | + | let currentKeyAddress = extract(addressFromString(currentKey)) | |
361 | + | let currentInvestorAssets = getAmount((keySumAssetsPrefix + currentKey)) | |
362 | + | let currentInvestorAmount = getAmount((keySumAmountPrefix + currentKey)) | |
363 | + | let currentInvestorSwapAssets = getAmount((swapKeySumAssetsPrefix + currentKey)) | |
364 | + | let currentInvestorSwapAmount = getAmount((swapKeySumAmountPrefix + currentKey)) | |
365 | + | let accountSwapAmount = getAmount(swapKeyCollectedAmount) | |
366 | + | let accountSwapAssets = getAmount(swapKeyDistAssets) | |
367 | + | let accountAmount = getAmount(keyCollectedAmount) | |
368 | + | let accountAssets = getAmount(keyDistAssets) | |
369 | + | let investmentAssetIdForTransfer = getInvestmentAssetIdForTransfer(investmentAssetIdIsWaves, investmentAssetId) | |
370 | + | if (!(companyHasEnded())) | |
371 | + | then throw("#0003 The Company is still active") | |
372 | + | else if (if ((currentKey == ownerAddressString)) | |
373 | + | then (dAppStatus == 1) | |
374 | + | else false) | |
375 | + | then { | |
376 | + | let issuerAlreadyGotFunds = getAmount(keyIssuer) | |
377 | + | if ((issuerAlreadyGotFunds == 0)) | |
378 | + | then if (if (isTokensaleAllow()) | |
379 | + | then isSwapAllow() | |
380 | + | else false) | |
381 | + | then if ((accountAmount >= softCapAmount)) | |
382 | + | then ScriptResult(WriteSet([DataEntry(keyIssuer, 1)]), TransferSet([ScriptTransfer(ownerAddress, accountAmount, investmentAssetIdForTransfer), ScriptTransfer(ownerAddress, accountSwapAmount, swapAssetId)])) | |
383 | + | else ScriptResult(WriteSet([DataEntry(keyIssuer, 1)]), TransferSet([ScriptTransfer(ownerAddress, accountSwapAmount, swapAssetId)])) | |
384 | + | else if (isTokensaleAllow()) | |
385 | + | then if ((accountAmount >= softCapAmount)) | |
386 | + | then ScriptResult(WriteSet([DataEntry(keyIssuer, 1)]), TransferSet([ScriptTransfer(ownerAddress, accountAmount, investmentAssetIdForTransfer)])) | |
387 | + | else throw("#0500 No funds for issuer") | |
388 | + | else ScriptResult(WriteSet([DataEntry(keyIssuer, 1)]), TransferSet([ScriptTransfer(ownerAddress, accountSwapAmount, swapAssetId)])) | |
389 | + | else throw("#0700 The issuer has already taken its share!") | |
390 | + | } | |
391 | + | else if (if ((currentInvestorAmount == 0)) | |
392 | + | then (currentInvestorSwapAmount == 0) | |
393 | + | else false) | |
394 | + | then throw("#0600 Don't have money") | |
395 | + | else if (if (isTokensaleAllow()) | |
396 | + | then isSwapAllow() | |
397 | + | else false) | |
398 | + | then if (if ((softCapAmount > accountAmount)) | |
399 | + | then (dAppStatus == 1) | |
400 | + | else false) | |
401 | + | then ScriptResult(WriteSet([DataEntry((keySumAmountPrefix + currentKey), 0), DataEntry((keySumAssetsPrefix + currentKey), 0), DataEntry((swapKeySumAmountPrefix + currentKey), 0), DataEntry((swapKeySumAssetsPrefix + currentKey), 0)]), TransferSet([ScriptTransfer(currentKeyAddress, currentInvestorAmount, investmentAssetIdForTransfer), ScriptTransfer(currentKeyAddress, currentInvestorSwapAssets, issuerAssetId)])) | |
402 | + | else if ((dAppStatus == 1)) | |
403 | + | then ScriptResult(WriteSet([DataEntry((keySumAmountPrefix + currentKey), 0), DataEntry((keySumAssetsPrefix + currentKey), 0), DataEntry((swapKeySumAmountPrefix + currentKey), 0), DataEntry((swapKeySumAssetsPrefix + currentKey), 0)]), TransferSet([ScriptTransfer(currentKeyAddress, currentInvestorAssets, issuerAssetId), ScriptTransfer(currentKeyAddress, currentInvestorSwapAssets, issuerAssetId)])) | |
404 | + | else ScriptResult(WriteSet([DataEntry((keySumAmountPrefix + currentKey), 0), DataEntry((keySumAssetsPrefix + currentKey), 0), DataEntry((swapKeySumAmountPrefix + currentKey), 0), DataEntry((swapKeySumAssetsPrefix + currentKey), 0)]), TransferSet([ScriptTransfer(currentKeyAddress, currentInvestorAmount, investmentAssetIdForTransfer), ScriptTransfer(currentKeyAddress, currentInvestorSwapAmount, swapAssetId)])) | |
405 | + | else if (isTokensaleAllow()) | |
406 | + | then if (if ((accountAmount >= softCapAmount)) | |
407 | + | then (dAppStatus == 1) | |
408 | + | else false) | |
409 | + | then ScriptResult(WriteSet([DataEntry((keySumAmountPrefix + currentKey), 0), DataEntry((keySumAssetsPrefix + currentKey), 0)]), TransferSet([ScriptTransfer(currentKeyAddress, currentInvestorAssets, issuerAssetId)])) | |
410 | + | else ScriptResult(WriteSet([DataEntry((keySumAmountPrefix + currentKey), 0), DataEntry((keySumAssetsPrefix + currentKey), 0)]), TransferSet([ScriptTransfer(currentKeyAddress, currentInvestorAmount, investmentAssetIdForTransfer)])) | |
411 | + | else if ((dAppStatus == 1)) | |
412 | + | then ScriptResult(WriteSet([DataEntry((swapKeySumAmountPrefix + currentKey), 0), DataEntry((swapKeySumAssetsPrefix + currentKey), 0)]), TransferSet([ScriptTransfer(currentKeyAddress, currentInvestorSwapAssets, issuerAssetId)])) | |
413 | + | else ScriptResult(WriteSet([DataEntry((swapKeySumAmountPrefix + currentKey), 0), DataEntry((swapKeySumAssetsPrefix + currentKey), 0)]), TransferSet([ScriptTransfer(currentKeyAddress, currentInvestorSwapAmount, swapAssetId)])) | |
414 | + | } | |
415 | + | } | |
416 | + | ||
417 | + | ||
418 | + | @Verifier(tx) | |
419 | + | func verify () = match tx { | |
420 | + | case tx: BurnTransaction => | |
421 | + | true | |
422 | + | case tx: ReissueTransaction => | |
423 | + | false | |
424 | + | case tx: DataTransaction|SetAssetScriptTransaction|SetScriptTransaction => | |
425 | + | let txId = toBase58String(tx.id) | |
426 | + | let pAddress1 = getAddressFromBook("pAddress1") | |
427 | + | let pAddress2 = getAddressFromBook("pAddress2") | |
428 | + | let pAddress3 = getAddressFromBook("pAddress3") | |
429 | + | let pAddress4 = getAddressFromBook("pAddress4") | |
430 | + | let pAddress5 = getAddressFromBook("pAddress5") | |
431 | + | let pAddress6 = getAddressFromBook("pAddress6") | |
432 | + | let pAddress7 = getAddressFromBook("pAddress7") | |
433 | + | let pAddress8 = getAddressFromBook("pAddress8") | |
434 | + | let pKey1Signed = if (isDefined(getInteger(pAddress1, txId))) | |
435 | + | then 1 | |
436 | + | else 0 | |
437 | + | let pKey2Signed = if (isDefined(getInteger(pAddress2, txId))) | |
438 | + | then 1 | |
439 | + | else 0 | |
440 | + | let pKey3Signed = if (isDefined(getInteger(pAddress3, txId))) | |
441 | + | then 1 | |
442 | + | else 0 | |
443 | + | let pKey4Signed = if (isDefined(getInteger(pAddress4, txId))) | |
444 | + | then 1 | |
445 | + | else 0 | |
446 | + | let pKey5Signed = if (isDefined(getInteger(pAddress5, txId))) | |
447 | + | then 1 | |
448 | + | else 0 | |
449 | + | let pKey6Signed = if (isDefined(getInteger(pAddress6, txId))) | |
450 | + | then 1 | |
451 | + | else 0 | |
452 | + | let pKey7Signed = if (isDefined(getInteger(pAddress7, txId))) | |
453 | + | then 1 | |
454 | + | else 0 | |
455 | + | let pKey8Signed = if (isDefined(getInteger(pAddress8, txId))) | |
456 | + | then 1 | |
457 | + | else 0 | |
458 | + | ((((((((pKey1Signed + pKey2Signed) + pKey3Signed) + pKey4Signed) + pKey5Signed) + pKey6Signed) + pKey7Signed) + pKey8Signed) >= 3) | |
459 | + | case _ => | |
460 | + | false | |
461 | + | } | |
462 | + |
github/deemru/w8io/169f3d6 26.90 ms ◑