tx · FW3zHnV1ArbfWPUQ9LnpjbYyUtVf98jFotirpxFB9rrv 3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg: -0.01000000 Waves 2022.03.28 10:02 [1983437] smart account 3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg > SELF 0.00000000 Waves
{ "type": 13, "id": "FW3zHnV1ArbfWPUQ9LnpjbYyUtVf98jFotirpxFB9rrv", "fee": 1000000, "feeAssetId": null, "timestamp": 1648450967608, "version": 2, "chainId": 84, "sender": "3N9yMmmL5cJ7LJxr8o6GFbKFUbGz4XcAjeg", "senderPublicKey": "C2aAS9D6FqfbrkCuCQCtPWAiopjyagvitFLjRuLcRPYt", "proofs": [ "3eszXbE8G9keoHAAHgXnzEndUNwHs4BzLi6yijrbbA2LkmjLt72ECF6BWqZn9WCYFtjsyDXFXDQHXF3d94MDL8Gt" ], "script": "base64:AAIFAAAAAAAAAEgIAhIMCgoICAgBCAEBAQEBEgQKAggIEgQKAggEEgMKAQgSBAoCCAESABIDCgEBEgASABIDCgEBEgASAwoBARIDCgEBEgMKAQgAAAA6AAAAAAlzZXBhcmF0b3ICAAAAAl9fAAAAAA9tYXhEZXB0aERlZmF1bHQAAAAAAAAAAAoBAAAABWFzSW50AAAAAQAAAAN2YWwEAAAAByRtYXRjaDAFAAAAA3ZhbAMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAADSW50BAAAAAZ2YWxJbnQFAAAAByRtYXRjaDAFAAAABnZhbEludAkAAAIAAAABAgAAABtGYWlsZWQgdG8gY2FzdCBpbnRvIEludGVnZXIBAAAABmFzQm9vbAAAAAEAAAADdmFsBAAAAAckbWF0Y2gwBQAAAAN2YWwDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAB0Jvb2xlYW4EAAAAB3ZhbEJvb2wFAAAAByRtYXRjaDAFAAAAB3ZhbEJvb2wJAAACAAAAAQIAAAAbRmFpbGVkIHRvIGNhc3QgaW50byBCb29sZWFuAAAAAAxrZXlGZWV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AQAAAAh0aGlzT25seQAAAAEFAAAAAWkDCQAAAAAAAAIFAAAAC2NoZWNrQ2FsbGVyBQAAAAtjaGVja0NhbGxlcgkABRQAAAACCQAETAAAAAIJAQAAAAxJbnRlZ2VyRW50cnkAAAACBQAAABJrZXlWb3RpbmdUaHJlc2hvbGQFAAAADG5ld1RocmVzaG9sZAUAAAADbmlsBQAAAAR1bml0CQAAAgAAAAECAAAAJFN0cmljdCB2YWx1ZSBpcyBub3QgZXF1YWwgdG8gaXRzZWxmLgAAAAFpAQAAAAZzZXRGZWUAAAABAAAABm5ld0ZlZQQAAAALY2hlY2tDYWxsZXIJAQAAAAh0aGlzT25seQAAAAEFAAAAAWkDCQAAAAAAAAIFAAAAC2NoZWNrQ2FsbGVyBQAAAAtjaGVja0NhbGxlcgkABRQAAAACCQAETAAAAAIJAQAAAAxJbnRlZ2VyRW50cnkAAAACBQAAAAxrZXlGZWVBbW91bnQFAAAABm5ld0ZlZQUAAAADbmlsBQAAAAR1bml0CQAAAgAAAAECAAAAJFN0cmljdCB2YWx1ZSBpcyBub3QgZXF1YWwgdG8gaXRzZWxmLgAAAAFpAQAAABtnd3hBdmFpbGFibGVGb3JWb3RlUkVBRE9OTFkAAAABAAAAC3VzZXJBZGRyZXNzBAAAAAllbmRIZWlnaHQJAABkAAAAAgUAAAALc3RhcnRIZWlnaHQFAAAADnZvdGluZ0R1cmF0aW9uBAAAAA5nd3hBbW91bnRBdEVuZAkBAAAAGGdldFVzZXJHd3hBbW91bnRBdEhlaWdodAAAAAIFAAAAC3VzZXJBZGRyZXNzBQAAAAllbmRIZWlnaHQJAAUUAAAAAgUAAAADbmlsBQAAAA5nd3hBbW91bnRBdEVuZAAAAABXu9Qv", "height": 1983437, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 4Tyo7A6gixTmMsnS1UfWhxWzvoEUWCEStjinyEjmCkUb Next: 9vUSWcpSF7614QcjHSJnyULRdbCjekxd2Fd8yqYPrGzV Diff:
Old | New | Differences | |
---|---|---|---|
77 | 77 | func keyVoteResultByPeriod (assetId,period) = makeString(["%s%d%s", "votingResultAtAsset", toString(period), assetId], separator) | |
78 | 78 | ||
79 | 79 | ||
80 | - | func formatVoteResult (totalYes,totalNo) = makeString(["%d%d", toString(totalYes), toString(totalNo)], separator) | |
80 | + | func formatVoteResult (totalYes,totalNo,verified) = makeString(["%d%d%s", toString(totalYes), toString(totalNo), toString(verified)], separator) | |
81 | 81 | ||
82 | 82 | ||
83 | 83 | func parseVoteResult (input) = { | |
84 | 84 | let parts = split(input, separator) | |
85 | 85 | let totalYesIdx = 1 | |
86 | 86 | let totalNoIdx = 2 | |
87 | + | let verifiedIdx = 3 | |
87 | 88 | let totalYes = parseIntValue(parts[totalYesIdx]) | |
88 | 89 | let totalNo = parseIntValue(parts[totalNoIdx]) | |
89 | - | $Tuple2(totalYes, totalNo) | |
90 | + | let verified = (parts[verifiedIdx] == "true") | |
91 | + | $Tuple3(totalYes, totalNo, verified) | |
90 | 92 | } | |
91 | 93 | ||
92 | 94 | ||
180 | 182 | } | |
181 | 183 | ||
182 | 184 | ||
183 | - | func getVoteResultAction (assetId,total,inFavor,period) = { | |
185 | + | func getVoteResultAction (assetId,total,inFavor,period,verified) = { | |
184 | 186 | let voteResultKey = keyVoteResultByPeriod(assetId, period) | |
185 | - | let $ | |
187 | + | let $t055955898 = match getString(voteResultKey) { | |
186 | 188 | case s: String => | |
187 | 189 | parseVoteResult(s) | |
188 | 190 | case _: Unit => | |
189 | - | $Tuple2(0, 0) | |
191 | + | match getString(keyVoteResultByPeriod(assetId, (period - 1))) { | |
192 | + | case s: String => | |
193 | + | $Tuple3(0, 0, parseVoteResult(s)._3) | |
194 | + | case _: Unit => | |
195 | + | $Tuple3(0, 0, false) | |
196 | + | case _ => | |
197 | + | throw("Match error") | |
198 | + | } | |
190 | 199 | case _ => | |
191 | 200 | throw("Match error") | |
192 | 201 | } | |
193 | - | let totalYes = $t054515583._1 | |
194 | - | let totalNo = $t054515583._2 | |
195 | - | StringEntry(voteResultKey, formatVoteResult((totalYes + (if (inFavor) | |
202 | + | let oldTotalYes = $t055955898._1 | |
203 | + | let oldTotalNo = $t055955898._2 | |
204 | + | let oldVerified = $t055955898._3 | |
205 | + | StringEntry(voteResultKey, formatVoteResult((oldTotalYes + (if (inFavor) | |
196 | 206 | then total | |
197 | - | else 0)), ( | |
207 | + | else 0)), (oldTotalNo + (if (inFavor) | |
198 | 208 | then 0 | |
199 | - | else total)))) | |
209 | + | else total)), if ((verified == unit)) | |
210 | + | then oldVerified | |
211 | + | else value(verified))) | |
200 | 212 | } | |
201 | 213 | ||
202 | 214 | ||
268 | 280 | if ((userPreviousVoteOrUnit == unit)) | |
269 | 281 | then nil | |
270 | 282 | else { | |
271 | - | let $ | |
272 | - | let prevTotal = $ | |
273 | - | let inFavor = $ | |
283 | + | let $t097929865 = parseUserVote(value(userPreviousVoteOrUnit)) | |
284 | + | let prevTotal = $t097929865._1 | |
285 | + | let inFavor = $t097929865._2 | |
274 | 286 | let total = min([prevTotal, userGwxAmountAtEndHeight]) | |
275 | - | [StringEntry(userVoteKey, formatUserVote(total, inFavor)), getVoteResultAction(assetId, total, inFavor, currentPeriod)] | |
287 | + | [StringEntry(userVoteKey, formatUserVote(total, inFavor)), getVoteResultAction(assetId, total, inFavor, currentPeriod, unit)] | |
276 | 288 | } | |
277 | 289 | } | |
278 | 290 | else nil | |
337 | 349 | if ((burnFeeInv == burnFeeInv)) | |
338 | 350 | then { | |
339 | 351 | let addAssetActions = insertNode(assetsListName, assetId) | |
340 | - | $Tuple2((addAssetActions :+ getVoteResultAction(assetId, 0, true, currentPeriod)), unit) | |
352 | + | $Tuple2((addAssetActions :+ getVoteResultAction(assetId, 0, true, currentPeriod, false)), unit) | |
341 | 353 | } | |
342 | 354 | else throw("Strict value is not equal to itself.") | |
343 | 355 | } | |
370 | 382 | then { | |
371 | 383 | let votesListName = getVotesListName(assetId) | |
372 | 384 | let userVoteKey = keyUserVoteByPeriod(userAddress, assetId, currentPeriod) | |
373 | - | let userVoteActions = [StringEntry(userVoteKey, formatUserVote(gwxAmountAtEnd, inFavor)), StringEntry(keyUserVoteHistory("vote", userAddress, assetId, toBase58String(i.transactionId), currentPeriod), formatUserVote(gwxAmountAtEnd, inFavor)), getVoteResultAction(assetId, gwxAmountAtEnd, inFavor, currentPeriod)] | |
385 | + | let userVoteActions = [StringEntry(userVoteKey, formatUserVote(gwxAmountAtEnd, inFavor)), StringEntry(keyUserVoteHistory("vote", userAddress, assetId, toBase58String(i.transactionId), currentPeriod), formatUserVote(gwxAmountAtEnd, inFavor)), getVoteResultAction(assetId, gwxAmountAtEnd, inFavor, currentPeriod, unit)] | |
374 | 386 | let votesListActions = if (containsNode(votesListName, userAddress)) | |
375 | 387 | then nil | |
376 | 388 | else insertNode(votesListName, userAddress) | |
394 | 406 | let checkVote = valueOrElse(getString(userVoteKey), "Nothing to cancel") | |
395 | 407 | if ((checkVote == checkVote)) | |
396 | 408 | then { | |
397 | - | let $ | |
398 | - | let total = $ | |
399 | - | let inFavor = $ | |
409 | + | let $t01498115042 = parseUserVote(value(userVoteOrUnit)) | |
410 | + | let total = $t01498115042._1 | |
411 | + | let inFavor = $t01498115042._2 | |
400 | 412 | let votesListActions = deleteNode(votesListName, userAddress) | |
401 | - | let userVoteActions = [DeleteEntry(userVoteKey), StringEntry(keyUserVoteHistory("cancelVote", userAddress, assetId, toBase58String(i.transactionId), currentPeriod), formatUserVote(0, true)), getVoteResultAction(assetId, -(total), inFavor, currentPeriod)] | |
413 | + | let userVoteActions = [DeleteEntry(userVoteKey), StringEntry(keyUserVoteHistory("cancelVote", userAddress, assetId, toBase58String(i.transactionId), currentPeriod), formatUserVote(0, true)), getVoteResultAction(assetId, -(total), inFavor, currentPeriod, unit)] | |
402 | 414 | $Tuple2((votesListActions ++ userVoteActions), unit) | |
403 | 415 | } | |
404 | 416 | else throw("Strict value is not equal to itself.") | |
412 | 424 | if ((checkCaller == checkCaller)) | |
413 | 425 | then { | |
414 | 426 | let voteResultKey = keyVoteResultByPeriod(assetId, period) | |
415 | - | let $ | |
427 | + | let $t01570215875 = match getString(voteResultKey) { | |
416 | 428 | case s: String => | |
417 | - | parseVoteResult(s) | |
429 | + | let r = parseVoteResult(s) | |
430 | + | $Tuple2(r._1, r._2) | |
418 | 431 | case _: Unit => | |
419 | 432 | $Tuple2(0, 0) | |
420 | 433 | case _ => | |
421 | 434 | throw("Match error") | |
422 | 435 | } | |
423 | - | let totalYes = $ | |
424 | - | let totalNo = $ | |
436 | + | let totalYes = $t01570215875._1 | |
437 | + | let totalNo = $t01570215875._2 | |
425 | 438 | let total = (totalYes + totalNo) | |
426 | 439 | let verified = if ((total >= votingThreshold)) | |
427 | 440 | then (totalYes > totalNo) | |
435 | 448 | else eliminationCheck(assetId) | |
436 | 449 | let voteResultActions = if (eliminate) | |
437 | 450 | then nil | |
438 | - | else [getVoteResultAction(assetId, 0, true, (currentPeriod + 1))] | |
451 | + | else [getVoteResultAction(assetId, 0, true, (currentPeriod + 1), verified)] | |
439 | 452 | let votesListActions = if (eliminate) | |
440 | 453 | then deleteNode(assetsListName, assetId) | |
441 | 454 | else nil |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let separator = "__" | |
5 | 5 | ||
6 | 6 | let maxDepthDefault = 10 | |
7 | 7 | ||
8 | 8 | func asInt (val) = match val { | |
9 | 9 | case valInt: Int => | |
10 | 10 | valInt | |
11 | 11 | case _ => | |
12 | 12 | throw("Failed to cast into Integer") | |
13 | 13 | } | |
14 | 14 | ||
15 | 15 | ||
16 | 16 | func asBool (val) = match val { | |
17 | 17 | case valBool: Boolean => | |
18 | 18 | valBool | |
19 | 19 | case _ => | |
20 | 20 | throw("Failed to cast into Boolean") | |
21 | 21 | } | |
22 | 22 | ||
23 | 23 | ||
24 | 24 | let keyFeeAmount = makeString(["%s", "fee"], separator) | |
25 | 25 | ||
26 | 26 | let keyWxAssetId = makeString(["%s", "wxAssetId"], separator) | |
27 | 27 | ||
28 | 28 | let keyVotingThreshold = makeString(["%s", "votingThreshold"], separator) | |
29 | 29 | ||
30 | 30 | let keyVotingDuration = makeString(["%s", "epochLength"], separator) | |
31 | 31 | ||
32 | 32 | let keyVoteBeforeElimination = makeString(["%s", "voteBeforeElimination"], separator) | |
33 | 33 | ||
34 | 34 | let keyStartHeight = makeString(["%s", "currentVotingHeightStart"], separator) | |
35 | 35 | ||
36 | 36 | let keyCurrentPeriod = makeString(["%s", "currentEpoch"], separator) | |
37 | 37 | ||
38 | 38 | let keyBoostingContract = makeString(["%s", "boostingContract"], separator) | |
39 | 39 | ||
40 | 40 | let keyEmissionContract = makeString(["%s", "emissionContract"], separator) | |
41 | 41 | ||
42 | 42 | let keyAssetsStoreContract = makeString(["%s", "assetsStoreContract"], separator) | |
43 | 43 | ||
44 | 44 | let keyLatestProcessedAsset = makeString(["%s", "latestProcessedAsset"], separator) | |
45 | 45 | ||
46 | 46 | let keyLatestProcessedUser = makeString(["%s", "latestProcessedUser"], separator) | |
47 | 47 | ||
48 | 48 | let keyLatestProcessedAssetTransfer = makeString(["%s", "latestProcessedAssetTransfer"], separator) | |
49 | 49 | ||
50 | 50 | let keyLatestProcessedUserTransfer = makeString(["%s", "latestProcessedUserTransfer"], separator) | |
51 | 51 | ||
52 | 52 | let keyMaxDepth = makeString(["%s", "maxDepth"], separator) | |
53 | 53 | ||
54 | 54 | func keyVotesTransferFinishedByPeriod (period) = makeString(["%s", "votesTransferFinished", toString(period)], separator) | |
55 | 55 | ||
56 | 56 | ||
57 | 57 | let assetsListName = "__assets" | |
58 | 58 | ||
59 | 59 | func getVotesListName (assetId) = ("%s__votes__" + assetId) | |
60 | 60 | ||
61 | 61 | ||
62 | 62 | func keyListHead (listName) = makeString([("%s%s" + listName), "head"], separator) | |
63 | 63 | ||
64 | 64 | ||
65 | 65 | func keyListSize (listName) = makeString([("%s%s" + listName), "size"], separator) | |
66 | 66 | ||
67 | 67 | ||
68 | 68 | func keyListPrev (listName,id) = makeString([("%s%s%s" + listName), id, "prev"], separator) | |
69 | 69 | ||
70 | 70 | ||
71 | 71 | func keyListNext (listName,id) = makeString([("%s%s%s" + listName), id, "next"], separator) | |
72 | 72 | ||
73 | 73 | ||
74 | 74 | func keyAssetVerifiedByPeriod (assetId,period) = makeString(["%s%d%s", "verifiedAt", toString(period), assetId], separator) | |
75 | 75 | ||
76 | 76 | ||
77 | 77 | func keyVoteResultByPeriod (assetId,period) = makeString(["%s%d%s", "votingResultAtAsset", toString(period), assetId], separator) | |
78 | 78 | ||
79 | 79 | ||
80 | - | func formatVoteResult (totalYes,totalNo) = makeString(["%d%d", toString(totalYes), toString(totalNo)], separator) | |
80 | + | func formatVoteResult (totalYes,totalNo,verified) = makeString(["%d%d%s", toString(totalYes), toString(totalNo), toString(verified)], separator) | |
81 | 81 | ||
82 | 82 | ||
83 | 83 | func parseVoteResult (input) = { | |
84 | 84 | let parts = split(input, separator) | |
85 | 85 | let totalYesIdx = 1 | |
86 | 86 | let totalNoIdx = 2 | |
87 | + | let verifiedIdx = 3 | |
87 | 88 | let totalYes = parseIntValue(parts[totalYesIdx]) | |
88 | 89 | let totalNo = parseIntValue(parts[totalNoIdx]) | |
89 | - | $Tuple2(totalYes, totalNo) | |
90 | + | let verified = (parts[verifiedIdx] == "true") | |
91 | + | $Tuple3(totalYes, totalNo, verified) | |
90 | 92 | } | |
91 | 93 | ||
92 | 94 | ||
93 | 95 | func keyUserVoteByPeriod (userAddress,assetId,period) = makeString(["%s%d%s%s", "vru", toString(period), assetId, userAddress], separator) | |
94 | 96 | ||
95 | 97 | ||
96 | 98 | func formatUserVote (total,inFavor) = { | |
97 | 99 | let totalYes = if (inFavor) | |
98 | 100 | then total | |
99 | 101 | else 0 | |
100 | 102 | let totalNo = if (inFavor) | |
101 | 103 | then 0 | |
102 | 104 | else total | |
103 | 105 | makeString(["%d%d", toString(totalYes), toString(totalNo)], separator) | |
104 | 106 | } | |
105 | 107 | ||
106 | 108 | ||
107 | 109 | func parseUserVote (input) = { | |
108 | 110 | let parts = split(input, separator) | |
109 | 111 | let totalYesIdx = 1 | |
110 | 112 | let totalNoIdx = 2 | |
111 | 113 | let totalYes = parseIntValue(parts[totalYesIdx]) | |
112 | 114 | let totalNo = parseIntValue(parts[totalNoIdx]) | |
113 | 115 | let inFavor = if ((totalYes > 0)) | |
114 | 116 | then (totalNo == 0) | |
115 | 117 | else false | |
116 | 118 | let against = if ((totalYes == 0)) | |
117 | 119 | then (totalNo > 0) | |
118 | 120 | else false | |
119 | 121 | let checkTotals = if (if (inFavor) | |
120 | 122 | then true | |
121 | 123 | else against) | |
122 | 124 | then true | |
123 | 125 | else throw("Invalid user vote value") | |
124 | 126 | if ((checkTotals == checkTotals)) | |
125 | 127 | then { | |
126 | 128 | let total = if (inFavor) | |
127 | 129 | then totalYes | |
128 | 130 | else totalNo | |
129 | 131 | $Tuple2(total, inFavor) | |
130 | 132 | } | |
131 | 133 | else throw("Strict value is not equal to itself.") | |
132 | 134 | } | |
133 | 135 | ||
134 | 136 | ||
135 | 137 | func keyUserVoteHistory (type,userAddress,assetId,txId,period) = makeString(["%s%s%s%s%s%d", "history", type, assetId, userAddress, txId, toString(period)], separator) | |
136 | 138 | ||
137 | 139 | ||
138 | 140 | func thisOnly (i) = if ((i.caller == this)) | |
139 | 141 | then true | |
140 | 142 | else throw("Permission denied") | |
141 | 143 | ||
142 | 144 | ||
143 | 145 | func getIntegerOrZero (key) = valueOrElse(getInteger(this, key), 0) | |
144 | 146 | ||
145 | 147 | ||
146 | 148 | func getIntegerOrFail (key) = valueOrErrorMessage(getInteger(this, key), (key + " is not defined")) | |
147 | 149 | ||
148 | 150 | ||
149 | 151 | func getStringOrEmpty (key) = valueOrElse(getString(this, key), "") | |
150 | 152 | ||
151 | 153 | ||
152 | 154 | func getStringOrFail (key) = valueOrErrorMessage(getString(this, key), (key + " is not defined")) | |
153 | 155 | ||
154 | 156 | ||
155 | 157 | let feeAmount = getIntegerOrFail(keyFeeAmount) | |
156 | 158 | ||
157 | 159 | let wxAssetId = fromBase58String(getStringOrFail(keyWxAssetId)) | |
158 | 160 | ||
159 | 161 | let votingThreshold = getIntegerOrFail(keyVotingThreshold) | |
160 | 162 | ||
161 | 163 | let votingDuration = getIntegerOrFail(keyVotingDuration) | |
162 | 164 | ||
163 | 165 | let voteBeforeElimination = getIntegerOrFail(keyVoteBeforeElimination) | |
164 | 166 | ||
165 | 167 | let startHeight = getIntegerOrFail(keyStartHeight) | |
166 | 168 | ||
167 | 169 | let currentPeriod = getIntegerOrFail(keyCurrentPeriod) | |
168 | 170 | ||
169 | 171 | let boostingContract = addressFromStringValue(getStringOrFail(keyBoostingContract)) | |
170 | 172 | ||
171 | 173 | let emissionContract = addressFromStringValue(getStringOrFail(keyEmissionContract)) | |
172 | 174 | ||
173 | 175 | let assetsStoreContract = addressFromStringValue(getStringOrFail(keyAssetsStoreContract)) | |
174 | 176 | ||
175 | 177 | let maxDepth = valueOrElse(getInteger(keyMaxDepth), maxDepthDefault) | |
176 | 178 | ||
177 | 179 | func getUserGwxAmountAtHeight (userAddress,targetHeight) = { | |
178 | 180 | let gwxAmount = invoke(boostingContract, "getUserGwxAmountAtHeightREADONLY", [userAddress, targetHeight], nil) | |
179 | 181 | asInt(gwxAmount) | |
180 | 182 | } | |
181 | 183 | ||
182 | 184 | ||
183 | - | func getVoteResultAction (assetId,total,inFavor,period) = { | |
185 | + | func getVoteResultAction (assetId,total,inFavor,period,verified) = { | |
184 | 186 | let voteResultKey = keyVoteResultByPeriod(assetId, period) | |
185 | - | let $ | |
187 | + | let $t055955898 = match getString(voteResultKey) { | |
186 | 188 | case s: String => | |
187 | 189 | parseVoteResult(s) | |
188 | 190 | case _: Unit => | |
189 | - | $Tuple2(0, 0) | |
191 | + | match getString(keyVoteResultByPeriod(assetId, (period - 1))) { | |
192 | + | case s: String => | |
193 | + | $Tuple3(0, 0, parseVoteResult(s)._3) | |
194 | + | case _: Unit => | |
195 | + | $Tuple3(0, 0, false) | |
196 | + | case _ => | |
197 | + | throw("Match error") | |
198 | + | } | |
190 | 199 | case _ => | |
191 | 200 | throw("Match error") | |
192 | 201 | } | |
193 | - | let totalYes = $t054515583._1 | |
194 | - | let totalNo = $t054515583._2 | |
195 | - | StringEntry(voteResultKey, formatVoteResult((totalYes + (if (inFavor) | |
202 | + | let oldTotalYes = $t055955898._1 | |
203 | + | let oldTotalNo = $t055955898._2 | |
204 | + | let oldVerified = $t055955898._3 | |
205 | + | StringEntry(voteResultKey, formatVoteResult((oldTotalYes + (if (inFavor) | |
196 | 206 | then total | |
197 | - | else 0)), ( | |
207 | + | else 0)), (oldTotalNo + (if (inFavor) | |
198 | 208 | then 0 | |
199 | - | else total)))) | |
209 | + | else total)), if ((verified == unit)) | |
210 | + | then oldVerified | |
211 | + | else value(verified))) | |
200 | 212 | } | |
201 | 213 | ||
202 | 214 | ||
203 | 215 | func containsNode (listName,id) = { | |
204 | 216 | let head = getString(this, keyListHead(listName)) | |
205 | 217 | let prev = getString(this, keyListPrev(listName, id)) | |
206 | 218 | let next = getString(this, keyListNext(listName, id)) | |
207 | 219 | if (if ((id == head)) | |
208 | 220 | then true | |
209 | 221 | else (prev != unit)) | |
210 | 222 | then true | |
211 | 223 | else (next != unit) | |
212 | 224 | } | |
213 | 225 | ||
214 | 226 | ||
215 | 227 | func insertNode (listName,id) = { | |
216 | 228 | let head = getString(this, keyListHead(listName)) | |
217 | 229 | let listSize = valueOrElse(getInteger(this, keyListSize(listName)), 0) | |
218 | 230 | let checkNode = if (!(containsNode(listName, id))) | |
219 | 231 | then true | |
220 | 232 | else throw("Node exists") | |
221 | 233 | if ((checkNode == checkNode)) | |
222 | 234 | then (([IntegerEntry(keyListSize(listName), (listSize + 1))] ++ (if (isDefined(head)) | |
223 | 235 | then [StringEntry(keyListNext(listName, id), value(head)), StringEntry(keyListPrev(listName, value(head)), id)] | |
224 | 236 | else nil)) ++ [StringEntry(keyListHead(listName), id)]) | |
225 | 237 | else throw("Strict value is not equal to itself.") | |
226 | 238 | } | |
227 | 239 | ||
228 | 240 | ||
229 | 241 | func deleteNode (listName,id) = { | |
230 | 242 | let head = getString(this, keyListHead(listName)) | |
231 | 243 | let listSize = valueOrElse(getInteger(this, keyListSize(listName)), 0) | |
232 | 244 | let prev = getString(this, keyListPrev(listName, id)) | |
233 | 245 | let next = getString(this, keyListNext(listName, id)) | |
234 | 246 | ([IntegerEntry(keyListSize(listName), (listSize - 1))] ++ (if (if (isDefined(prev)) | |
235 | 247 | then isDefined(next) | |
236 | 248 | else false) | |
237 | 249 | then [StringEntry(keyListNext(listName, value(prev)), value(next)), StringEntry(keyListPrev(listName, value(next)), value(prev)), DeleteEntry(keyListPrev(listName, id)), DeleteEntry(keyListNext(listName, id))] | |
238 | 250 | else if (isDefined(next)) | |
239 | 251 | then [StringEntry(keyListHead(listName), value(next)), DeleteEntry(keyListNext(listName, id)), DeleteEntry(keyListPrev(listName, value(next)))] | |
240 | 252 | else if (isDefined(prev)) | |
241 | 253 | then [DeleteEntry(keyListPrev(listName, id)), DeleteEntry(keyListNext(listName, value(prev)))] | |
242 | 254 | else if ((id == head)) | |
243 | 255 | then [DeleteEntry(keyListHead(listName))] | |
244 | 256 | else throw("Invalid node"))) | |
245 | 257 | } | |
246 | 258 | ||
247 | 259 | ||
248 | 260 | func processVote (assetId,userAddressOrUnit,latestProcessedAssetKey,latestProcessedUserKey) = { | |
249 | 261 | let updateLatestProcessedAssetAction = StringEntry(latestProcessedAssetKey, assetId) | |
250 | 262 | let deleteLatestProcessedUserAction = DeleteEntry(latestProcessedUserKey) | |
251 | 263 | if ((userAddressOrUnit == unit)) | |
252 | 264 | then [updateLatestProcessedAssetAction, deleteLatestProcessedUserAction] | |
253 | 265 | else { | |
254 | 266 | let endHeight = (startHeight + votingDuration) | |
255 | 267 | let userAddress = value(userAddressOrUnit) | |
256 | 268 | let updateLatestProcessedUserAction = StringEntry(latestProcessedUserKey, userAddress) | |
257 | 269 | let userVoteKey = keyUserVoteByPeriod(userAddress, assetId, currentPeriod) | |
258 | 270 | let userVoteOrUnit = getString(userVoteKey) | |
259 | 271 | let userGwxAmountAtEndHeight = getUserGwxAmountAtHeight(userAddress, endHeight) | |
260 | 272 | let voteActions = if ((userGwxAmountAtEndHeight == 0)) | |
261 | 273 | then { | |
262 | 274 | let votesListName = getVotesListName(assetId) | |
263 | 275 | deleteNode(votesListName, userAddress) | |
264 | 276 | } | |
265 | 277 | else if ((userVoteOrUnit == unit)) | |
266 | 278 | then { | |
267 | 279 | let userPreviousVoteOrUnit = getString(keyUserVoteByPeriod(userAddress, assetId, (currentPeriod - 1))) | |
268 | 280 | if ((userPreviousVoteOrUnit == unit)) | |
269 | 281 | then nil | |
270 | 282 | else { | |
271 | - | let $ | |
272 | - | let prevTotal = $ | |
273 | - | let inFavor = $ | |
283 | + | let $t097929865 = parseUserVote(value(userPreviousVoteOrUnit)) | |
284 | + | let prevTotal = $t097929865._1 | |
285 | + | let inFavor = $t097929865._2 | |
274 | 286 | let total = min([prevTotal, userGwxAmountAtEndHeight]) | |
275 | - | [StringEntry(userVoteKey, formatUserVote(total, inFavor)), getVoteResultAction(assetId, total, inFavor, currentPeriod)] | |
287 | + | [StringEntry(userVoteKey, formatUserVote(total, inFavor)), getVoteResultAction(assetId, total, inFavor, currentPeriod, unit)] | |
276 | 288 | } | |
277 | 289 | } | |
278 | 290 | else nil | |
279 | 291 | ((voteActions :+ updateLatestProcessedAssetAction) :+ updateLatestProcessedUserAction) | |
280 | 292 | } | |
281 | 293 | } | |
282 | 294 | ||
283 | 295 | ||
284 | 296 | func assetShouldBeEliminated (assetId,period) = !(valueOrElse(getBoolean(keyAssetVerifiedByPeriod(assetId, period)), true)) | |
285 | 297 | ||
286 | 298 | ||
287 | 299 | func eliminationCheck (assetId) = if (if (assetShouldBeEliminated(assetId, (currentPeriod - 1))) | |
288 | 300 | then assetShouldBeEliminated(assetId, (currentPeriod - 2)) | |
289 | 301 | else false) | |
290 | 302 | then assetShouldBeEliminated(assetId, (currentPeriod - 3)) | |
291 | 303 | else false | |
292 | 304 | ||
293 | 305 | ||
294 | 306 | @Callable(i) | |
295 | 307 | func constructor (boostingContractPrm,emissionContractPrm,assetsStoreContractPrm,feeAmountPrm,wxAssetIdPrm,votingThresholdPrm,votingDurationPrm,voteBeforeEliminationPrm,startHeightPrm,maxDepthPrm) = { | |
296 | 308 | let checks = [thisOnly(i), if (isDefined(addressFromString(boostingContractPrm))) | |
297 | 309 | then true | |
298 | 310 | else throw("Invalid boosting contract address"), if (isDefined(addressFromString(emissionContractPrm))) | |
299 | 311 | then true | |
300 | 312 | else throw("Invalid emission contract address"), if (isDefined(addressFromString(assetsStoreContractPrm))) | |
301 | 313 | then true | |
302 | 314 | else throw("Invalid asset_store contract address"), if ((feeAmountPrm >= 0)) | |
303 | 315 | then true | |
304 | 316 | else throw("Invalid fee amount"), if (isDefined(assetInfo(fromBase58String(wxAssetIdPrm)))) | |
305 | 317 | then true | |
306 | 318 | else throw("Invalid WX asset ID"), if ((votingThresholdPrm >= 0)) | |
307 | 319 | then true | |
308 | 320 | else throw("Invalid voting threshold"), if ((votingDurationPrm > 0)) | |
309 | 321 | then true | |
310 | 322 | else throw("Invalid voting duration"), if (((startHeightPrm + votingDurationPrm) > height)) | |
311 | 323 | then true | |
312 | 324 | else throw("Invalid start height")] | |
313 | 325 | if ((checks == checks)) | |
314 | 326 | then $Tuple2([StringEntry(keyBoostingContract, boostingContractPrm), StringEntry(keyEmissionContract, emissionContractPrm), StringEntry(keyAssetsStoreContract, assetsStoreContractPrm), IntegerEntry(keyFeeAmount, feeAmountPrm), StringEntry(keyWxAssetId, wxAssetIdPrm), IntegerEntry(keyVotingThreshold, votingThresholdPrm), IntegerEntry(keyVotingDuration, votingDurationPrm), IntegerEntry(keyVoteBeforeElimination, voteBeforeEliminationPrm), IntegerEntry(keyStartHeight, startHeightPrm), IntegerEntry(keyCurrentPeriod, 0), IntegerEntry(keyMaxDepth, maxDepthPrm)], unit) | |
315 | 327 | else throw("Strict value is not equal to itself.") | |
316 | 328 | } | |
317 | 329 | ||
318 | 330 | ||
319 | 331 | ||
320 | 332 | @Callable(i) | |
321 | 333 | func suggest (assetId,assetImage) = { | |
322 | 334 | let info = valueOrErrorMessage(assetInfo(fromBase58String(assetId)), "Invalid asset ID") | |
323 | 335 | let payment = value(i.payments[0]) | |
324 | 336 | let checks = [if ((info.issuer == i.caller)) | |
325 | 337 | then true | |
326 | 338 | else throw("Asset can only be suggested by its issuer"), if ((value(payment.assetId) == wxAssetId)) | |
327 | 339 | then true | |
328 | 340 | else throw("Invalid fee asset"), if ((payment.amount == feeAmount)) | |
329 | 341 | then true | |
330 | 342 | else throw("Invalid fee amount")] | |
331 | 343 | if ((checks == checks)) | |
332 | 344 | then { | |
333 | 345 | let assetsStoreCreateOrUpdateInv = invoke(assetsStoreContract, "createOrUpdate", [assetId, "", assetImage, false], nil) | |
334 | 346 | if ((assetsStoreCreateOrUpdateInv == assetsStoreCreateOrUpdateInv)) | |
335 | 347 | then { | |
336 | 348 | let burnFeeInv = invoke(emissionContract, "burn", nil, [AttachedPayment(payment.assetId, payment.amount)]) | |
337 | 349 | if ((burnFeeInv == burnFeeInv)) | |
338 | 350 | then { | |
339 | 351 | let addAssetActions = insertNode(assetsListName, assetId) | |
340 | - | $Tuple2((addAssetActions :+ getVoteResultAction(assetId, 0, true, currentPeriod)), unit) | |
352 | + | $Tuple2((addAssetActions :+ getVoteResultAction(assetId, 0, true, currentPeriod, false)), unit) | |
341 | 353 | } | |
342 | 354 | else throw("Strict value is not equal to itself.") | |
343 | 355 | } | |
344 | 356 | else throw("Strict value is not equal to itself.") | |
345 | 357 | } | |
346 | 358 | else throw("Strict value is not equal to itself.") | |
347 | 359 | } | |
348 | 360 | ||
349 | 361 | ||
350 | 362 | ||
351 | 363 | @Callable(i) | |
352 | 364 | func vote (assetId,inFavor) = { | |
353 | 365 | let endHeight = (startHeight + votingDuration) | |
354 | 366 | let checkAsset = if (containsNode(assetsListName, assetId)) | |
355 | 367 | then true | |
356 | 368 | else throw("Invalid asset") | |
357 | 369 | if ((checkAsset == checkAsset)) | |
358 | 370 | then { | |
359 | 371 | let checkHeight = if ((endHeight > height)) | |
360 | 372 | then true | |
361 | 373 | else throw("Current voting is over but results are not finalized") | |
362 | 374 | if ((checkHeight == checkHeight)) | |
363 | 375 | then { | |
364 | 376 | let userAddress = toString(i.caller) | |
365 | 377 | let gwxAmountAtEnd = getUserGwxAmountAtHeight(userAddress, endHeight) | |
366 | 378 | let checkGwxAmountAtEnd = if ((gwxAmountAtEnd > 0)) | |
367 | 379 | then true | |
368 | 380 | else throw("You'll not have gWX at the end of voting") | |
369 | 381 | if ((checkGwxAmountAtEnd == checkGwxAmountAtEnd)) | |
370 | 382 | then { | |
371 | 383 | let votesListName = getVotesListName(assetId) | |
372 | 384 | let userVoteKey = keyUserVoteByPeriod(userAddress, assetId, currentPeriod) | |
373 | - | let userVoteActions = [StringEntry(userVoteKey, formatUserVote(gwxAmountAtEnd, inFavor)), StringEntry(keyUserVoteHistory("vote", userAddress, assetId, toBase58String(i.transactionId), currentPeriod), formatUserVote(gwxAmountAtEnd, inFavor)), getVoteResultAction(assetId, gwxAmountAtEnd, inFavor, currentPeriod)] | |
385 | + | let userVoteActions = [StringEntry(userVoteKey, formatUserVote(gwxAmountAtEnd, inFavor)), StringEntry(keyUserVoteHistory("vote", userAddress, assetId, toBase58String(i.transactionId), currentPeriod), formatUserVote(gwxAmountAtEnd, inFavor)), getVoteResultAction(assetId, gwxAmountAtEnd, inFavor, currentPeriod, unit)] | |
374 | 386 | let votesListActions = if (containsNode(votesListName, userAddress)) | |
375 | 387 | then nil | |
376 | 388 | else insertNode(votesListName, userAddress) | |
377 | 389 | $Tuple2((votesListActions ++ userVoteActions), unit) | |
378 | 390 | } | |
379 | 391 | else throw("Strict value is not equal to itself.") | |
380 | 392 | } | |
381 | 393 | else throw("Strict value is not equal to itself.") | |
382 | 394 | } | |
383 | 395 | else throw("Strict value is not equal to itself.") | |
384 | 396 | } | |
385 | 397 | ||
386 | 398 | ||
387 | 399 | ||
388 | 400 | @Callable(i) | |
389 | 401 | func cancelVote (assetId) = { | |
390 | 402 | let userAddress = toString(i.caller) | |
391 | 403 | let votesListName = getVotesListName(assetId) | |
392 | 404 | let userVoteKey = keyUserVoteByPeriod(userAddress, assetId, currentPeriod) | |
393 | 405 | let userVoteOrUnit = getString(userVoteKey) | |
394 | 406 | let checkVote = valueOrElse(getString(userVoteKey), "Nothing to cancel") | |
395 | 407 | if ((checkVote == checkVote)) | |
396 | 408 | then { | |
397 | - | let $ | |
398 | - | let total = $ | |
399 | - | let inFavor = $ | |
409 | + | let $t01498115042 = parseUserVote(value(userVoteOrUnit)) | |
410 | + | let total = $t01498115042._1 | |
411 | + | let inFavor = $t01498115042._2 | |
400 | 412 | let votesListActions = deleteNode(votesListName, userAddress) | |
401 | - | let userVoteActions = [DeleteEntry(userVoteKey), StringEntry(keyUserVoteHistory("cancelVote", userAddress, assetId, toBase58String(i.transactionId), currentPeriod), formatUserVote(0, true)), getVoteResultAction(assetId, -(total), inFavor, currentPeriod)] | |
413 | + | let userVoteActions = [DeleteEntry(userVoteKey), StringEntry(keyUserVoteHistory("cancelVote", userAddress, assetId, toBase58String(i.transactionId), currentPeriod), formatUserVote(0, true)), getVoteResultAction(assetId, -(total), inFavor, currentPeriod, unit)] | |
402 | 414 | $Tuple2((votesListActions ++ userVoteActions), unit) | |
403 | 415 | } | |
404 | 416 | else throw("Strict value is not equal to itself.") | |
405 | 417 | } | |
406 | 418 | ||
407 | 419 | ||
408 | 420 | ||
409 | 421 | @Callable(i) | |
410 | 422 | func finalizeAssetINTERNAL (assetId,period) = { | |
411 | 423 | let checkCaller = thisOnly(i) | |
412 | 424 | if ((checkCaller == checkCaller)) | |
413 | 425 | then { | |
414 | 426 | let voteResultKey = keyVoteResultByPeriod(assetId, period) | |
415 | - | let $ | |
427 | + | let $t01570215875 = match getString(voteResultKey) { | |
416 | 428 | case s: String => | |
417 | - | parseVoteResult(s) | |
429 | + | let r = parseVoteResult(s) | |
430 | + | $Tuple2(r._1, r._2) | |
418 | 431 | case _: Unit => | |
419 | 432 | $Tuple2(0, 0) | |
420 | 433 | case _ => | |
421 | 434 | throw("Match error") | |
422 | 435 | } | |
423 | - | let totalYes = $ | |
424 | - | let totalNo = $ | |
436 | + | let totalYes = $t01570215875._1 | |
437 | + | let totalNo = $t01570215875._2 | |
425 | 438 | let total = (totalYes + totalNo) | |
426 | 439 | let verified = if ((total >= votingThreshold)) | |
427 | 440 | then (totalYes > totalNo) | |
428 | 441 | else false | |
429 | 442 | let assetVerifiedAction = [BooleanEntry(keyAssetVerifiedByPeriod(assetId, period), verified)] | |
430 | 443 | let assetsStoreSetVerifiedInv = invoke(assetsStoreContract, "setVerified", [assetId, verified], nil) | |
431 | 444 | if ((assetsStoreSetVerifiedInv == assetsStoreSetVerifiedInv)) | |
432 | 445 | then { | |
433 | 446 | let eliminate = if (verified) | |
434 | 447 | then false | |
435 | 448 | else eliminationCheck(assetId) | |
436 | 449 | let voteResultActions = if (eliminate) | |
437 | 450 | then nil | |
438 | - | else [getVoteResultAction(assetId, 0, true, (currentPeriod + 1))] | |
451 | + | else [getVoteResultAction(assetId, 0, true, (currentPeriod + 1), verified)] | |
439 | 452 | let votesListActions = if (eliminate) | |
440 | 453 | then deleteNode(assetsListName, assetId) | |
441 | 454 | else nil | |
442 | 455 | $Tuple2(((votesListActions ++ voteResultActions) ++ assetVerifiedAction), unit) | |
443 | 456 | } | |
444 | 457 | else throw("Strict value is not equal to itself.") | |
445 | 458 | } | |
446 | 459 | else throw("Strict value is not equal to itself.") | |
447 | 460 | } | |
448 | 461 | ||
449 | 462 | ||
450 | 463 | ||
451 | 464 | @Callable(i) | |
452 | 465 | func finalizeVotingHelper () = { | |
453 | 466 | let endHeight = (startHeight + votingDuration) | |
454 | 467 | if ((endHeight > height)) | |
455 | 468 | then $Tuple2(nil, false) | |
456 | 469 | else { | |
457 | 470 | let latestProcessedAssetOrUnit = getString(keyLatestProcessedAsset) | |
458 | 471 | let latestProcessedUserOrUnit = getString(keyLatestProcessedUser) | |
459 | 472 | let nextPeriodDelay = 0 | |
460 | 473 | let finish = $Tuple2([IntegerEntry(keyStartHeight, (height + nextPeriodDelay)), IntegerEntry(keyCurrentPeriod, (currentPeriod + 1)), DeleteEntry(keyLatestProcessedAsset), DeleteEntry(keyLatestProcessedUser), DeleteEntry(keyLatestProcessedAssetTransfer), DeleteEntry(keyLatestProcessedUserTransfer)], true) | |
461 | 474 | if ((latestProcessedAssetOrUnit == unit)) | |
462 | 475 | then { | |
463 | 476 | let assetsHeadOrUnit = getString(keyListHead(assetsListName)) | |
464 | 477 | if ((assetsHeadOrUnit == unit)) | |
465 | 478 | then finish | |
466 | 479 | else { | |
467 | 480 | let asset = value(assetsHeadOrUnit) | |
468 | 481 | let userAddressOrUnit = getString(keyListHead(getVotesListName(asset))) | |
469 | 482 | let processVoteActions = processVote(asset, userAddressOrUnit, keyLatestProcessedAsset, keyLatestProcessedUser) | |
470 | 483 | $Tuple2(processVoteActions, true) | |
471 | 484 | } | |
472 | 485 | } | |
473 | 486 | else { | |
474 | 487 | let latestProcessedAsset = value(latestProcessedAssetOrUnit) | |
475 | 488 | if ((latestProcessedUserOrUnit == unit)) | |
476 | 489 | then { | |
477 | 490 | let assetOrUnit = getString(keyListNext(assetsListName, latestProcessedAsset)) | |
478 | 491 | if ((assetOrUnit == assetOrUnit)) | |
479 | 492 | then { | |
480 | 493 | let finalizeAssetInv = invoke(this, "finalizeAssetINTERNAL", [latestProcessedAsset, currentPeriod], nil) | |
481 | 494 | if ((finalizeAssetInv == finalizeAssetInv)) | |
482 | 495 | then if ((assetOrUnit == unit)) | |
483 | 496 | then finish | |
484 | 497 | else { | |
485 | 498 | let asset = value(assetOrUnit) | |
486 | 499 | let userAddressOrUnit = getString(keyListHead(getVotesListName(asset))) | |
487 | 500 | let processVoteActions = processVote(asset, userAddressOrUnit, keyLatestProcessedAsset, keyLatestProcessedUser) | |
488 | 501 | $Tuple2(processVoteActions, true) | |
489 | 502 | } | |
490 | 503 | else throw("Strict value is not equal to itself.") | |
491 | 504 | } | |
492 | 505 | else throw("Strict value is not equal to itself.") | |
493 | 506 | } | |
494 | 507 | else { | |
495 | 508 | let latestProcessedUser = value(latestProcessedUserOrUnit) | |
496 | 509 | let userAddressOrUnit = getString(keyListNext(getVotesListName(latestProcessedAsset), latestProcessedUser)) | |
497 | 510 | let processVoteActions = processVote(latestProcessedAsset, userAddressOrUnit, keyLatestProcessedAsset, keyLatestProcessedUser) | |
498 | 511 | $Tuple2(processVoteActions, true) | |
499 | 512 | } | |
500 | 513 | } | |
501 | 514 | } | |
502 | 515 | } | |
503 | 516 | ||
504 | 517 | ||
505 | 518 | ||
506 | 519 | @Callable(i) | |
507 | 520 | func finalizeVotingWrapper (counter) = { | |
508 | 521 | let result = asBool(invoke(this, "finalizeVotingHelper", nil, nil)) | |
509 | 522 | if ((result == result)) | |
510 | 523 | then if (!(result)) | |
511 | 524 | then if ((counter == 0)) | |
512 | 525 | then throw("Current voting is not over yet") | |
513 | 526 | else $Tuple2(nil, unit) | |
514 | 527 | else if ((maxDepth > counter)) | |
515 | 528 | then { | |
516 | 529 | let inv = invoke(this, "finalizeVotingWrapper", [(counter + 1)], nil) | |
517 | 530 | if ((inv == inv)) | |
518 | 531 | then $Tuple2(nil, unit) | |
519 | 532 | else throw("Strict value is not equal to itself.") | |
520 | 533 | } | |
521 | 534 | else $Tuple2(nil, unit) | |
522 | 535 | else throw("Strict value is not equal to itself.") | |
523 | 536 | } | |
524 | 537 | ||
525 | 538 | ||
526 | 539 | ||
527 | 540 | @Callable(i) | |
528 | 541 | func finalizeVoting () = { | |
529 | 542 | let inv = invoke(this, "finalizeVotingWrapper", [0], nil) | |
530 | 543 | if ((inv == inv)) | |
531 | 544 | then $Tuple2(nil, unit) | |
532 | 545 | else throw("Strict value is not equal to itself.") | |
533 | 546 | } | |
534 | 547 | ||
535 | 548 | ||
536 | 549 | ||
537 | 550 | @Callable(i) | |
538 | 551 | func transferVotesHelper () = { | |
539 | 552 | let votesTransferFinishedKey = keyVotesTransferFinishedByPeriod(currentPeriod) | |
540 | 553 | let votesTransferFinished = valueOrElse(getBoolean(votesTransferFinishedKey), false) | |
541 | 554 | let endHeight = (startHeight + votingDuration) | |
542 | 555 | if (if (if ((startHeight > height)) | |
543 | 556 | then true | |
544 | 557 | else (height >= endHeight)) | |
545 | 558 | then true | |
546 | 559 | else votesTransferFinished) | |
547 | 560 | then $Tuple2(nil, false) | |
548 | 561 | else { | |
549 | 562 | let latestProcessedAssetOrUnit = getString(keyLatestProcessedAssetTransfer) | |
550 | 563 | let latestProcessedUserOrUnit = getString(keyLatestProcessedUserTransfer) | |
551 | 564 | let finish = $Tuple2([BooleanEntry(votesTransferFinishedKey, true), DeleteEntry(keyLatestProcessedAssetTransfer), DeleteEntry(keyLatestProcessedUserTransfer)], true) | |
552 | 565 | if ((latestProcessedAssetOrUnit == unit)) | |
553 | 566 | then { | |
554 | 567 | let assetsHeadOrUnit = getString(keyListHead(assetsListName)) | |
555 | 568 | if ((assetsHeadOrUnit == unit)) | |
556 | 569 | then finish | |
557 | 570 | else { | |
558 | 571 | let asset = value(assetsHeadOrUnit) | |
559 | 572 | let userAddressOrUnit = getString(keyListHead(getVotesListName(asset))) | |
560 | 573 | let processVoteActions = processVote(asset, userAddressOrUnit, keyLatestProcessedAssetTransfer, keyLatestProcessedUserTransfer) | |
561 | 574 | $Tuple2(processVoteActions, true) | |
562 | 575 | } | |
563 | 576 | } | |
564 | 577 | else { | |
565 | 578 | let latestProcessedAsset = value(latestProcessedAssetOrUnit) | |
566 | 579 | if ((latestProcessedUserOrUnit == unit)) | |
567 | 580 | then { | |
568 | 581 | let assetOrUnit = getString(keyListNext(assetsListName, latestProcessedAsset)) | |
569 | 582 | if ((assetOrUnit == unit)) | |
570 | 583 | then finish | |
571 | 584 | else { | |
572 | 585 | let asset = value(assetOrUnit) | |
573 | 586 | let userAddressOrUnit = getString(keyListHead(getVotesListName(asset))) | |
574 | 587 | let processVoteActions = processVote(asset, userAddressOrUnit, keyLatestProcessedAssetTransfer, keyLatestProcessedUserTransfer) | |
575 | 588 | $Tuple2(processVoteActions, true) | |
576 | 589 | } | |
577 | 590 | } | |
578 | 591 | else { | |
579 | 592 | let latestProcessedUser = value(latestProcessedUserOrUnit) | |
580 | 593 | let userAddressOrUnit = getString(keyListNext(getVotesListName(latestProcessedAsset), latestProcessedUser)) | |
581 | 594 | let processVoteActions = processVote(latestProcessedAsset, userAddressOrUnit, keyLatestProcessedAssetTransfer, keyLatestProcessedUserTransfer) | |
582 | 595 | $Tuple2(processVoteActions, true) | |
583 | 596 | } | |
584 | 597 | } | |
585 | 598 | } | |
586 | 599 | } | |
587 | 600 | ||
588 | 601 | ||
589 | 602 | ||
590 | 603 | @Callable(i) | |
591 | 604 | func transferVotesWrapper (counter) = { | |
592 | 605 | let result = asBool(invoke(this, "transferVotesHelper", nil, nil)) | |
593 | 606 | if ((result == result)) | |
594 | 607 | then if (!(result)) | |
595 | 608 | then if ((counter == 0)) | |
596 | 609 | then throw("Voting is not started yet") | |
597 | 610 | else $Tuple2(nil, unit) | |
598 | 611 | else if ((maxDepth > counter)) | |
599 | 612 | then { | |
600 | 613 | let inv = invoke(this, "transferVotesWrapper", [(counter + 1)], nil) | |
601 | 614 | if ((inv == inv)) | |
602 | 615 | then $Tuple2(nil, unit) | |
603 | 616 | else throw("Strict value is not equal to itself.") | |
604 | 617 | } | |
605 | 618 | else $Tuple2(nil, unit) | |
606 | 619 | else throw("Strict value is not equal to itself.") | |
607 | 620 | } | |
608 | 621 | ||
609 | 622 | ||
610 | 623 | ||
611 | 624 | @Callable(i) | |
612 | 625 | func transferVotes () = { | |
613 | 626 | let inv = invoke(this, "transferVotesWrapper", [0], nil) | |
614 | 627 | if ((inv == inv)) | |
615 | 628 | then $Tuple2(nil, unit) | |
616 | 629 | else throw("Strict value is not equal to itself.") | |
617 | 630 | } | |
618 | 631 | ||
619 | 632 | ||
620 | 633 | ||
621 | 634 | @Callable(i) | |
622 | 635 | func setVotingThreshold (newThreshold) = { | |
623 | 636 | let checkCaller = thisOnly(i) | |
624 | 637 | if ((checkCaller == checkCaller)) | |
625 | 638 | then $Tuple2([IntegerEntry(keyVotingThreshold, newThreshold)], unit) | |
626 | 639 | else throw("Strict value is not equal to itself.") | |
627 | 640 | } | |
628 | 641 | ||
629 | 642 | ||
630 | 643 | ||
631 | 644 | @Callable(i) | |
632 | 645 | func setFee (newFee) = { | |
633 | 646 | let checkCaller = thisOnly(i) | |
634 | 647 | if ((checkCaller == checkCaller)) | |
635 | 648 | then $Tuple2([IntegerEntry(keyFeeAmount, newFee)], unit) | |
636 | 649 | else throw("Strict value is not equal to itself.") | |
637 | 650 | } | |
638 | 651 | ||
639 | 652 | ||
640 | 653 | ||
641 | 654 | @Callable(i) | |
642 | 655 | func gwxAvailableForVoteREADONLY (userAddress) = { | |
643 | 656 | let endHeight = (startHeight + votingDuration) | |
644 | 657 | let gwxAmountAtEnd = getUserGwxAmountAtHeight(userAddress, endHeight) | |
645 | 658 | $Tuple2(nil, gwxAmountAtEnd) | |
646 | 659 | } | |
647 | 660 | ||
648 | 661 |
github/deemru/w8io/026f985 103.19 ms ◑