tx · Hcb2NQsvWn5HWzuRASG7VaqGpEKtAvtJvqyAgA3w8yjy

3N1BEXuoepNEwqkbeZYKviaLQfvBQV3ibYE:  -0.02100000 Waves

2023.06.02 16:20 [2605117] smart account 3N1BEXuoepNEwqkbeZYKviaLQfvBQV3ibYE > SELF 0.00000000 Waves

{ "type": 13, "id": "Hcb2NQsvWn5HWzuRASG7VaqGpEKtAvtJvqyAgA3w8yjy", "fee": 2100000, "feeAssetId": null, "timestamp": 1685712041590, "version": 2, "chainId": 84, "sender": "3N1BEXuoepNEwqkbeZYKviaLQfvBQV3ibYE", "senderPublicKey": "6t3vrhP1jCmG7CeKBmL8hUibtdP3cMXGC2XtPYEPPC5w", "proofs": [ "4qT4XgARwPZPXvyZTbDggEC8475CqGcAz39HyLEARELiNPHt9Zu8gUWpDxdgegz7ch9eg7n6PTdstong7ePyAEdb" ], "script": "base64:BgIqCAISBQoDCAEIEgMKAQgSBAoCCAQSAwoBCBIDCgEIEgQKAggBEgQKAggBNQAJc2VwYXJhdG9yAgJfXwAFTVVMVDgAgMLXLwEHd3JhcEVycgEDbXNnCQC5CQIJAMwIAgIYdm90aW5nX3ZlcmlmaWVkX3YyLnJpZGU6CQDMCAIFA21zZwUDbmlsAgEgAQh0aHJvd0VycgEDbXNnCQACAQkBB3dyYXBFcnIBBQNtc2cBBWFzSW50AQN2YWwEByRtYXRjaDAFA3ZhbAMJAAECBQckbWF0Y2gwAgNJbnQEBnZhbEludAUHJG1hdGNoMAUGdmFsSW50CQACAQIbRmFpbGVkIHRvIGNhc3QgaW50byBJbnRlZ2VyARBnZXRJbnRlZ2VyT3JaZXJvAgdhZGRyZXNzA2tleQkBC3ZhbHVlT3JFbHNlAgkAmggCBQdhZGRyZXNzBQNrZXkAAAEQZ2V0SW50ZWdlck9yRmFpbAIHYWRkcmVzcwNrZXkJARN2YWx1ZU9yRXJyb3JNZXNzYWdlAgkAmggCBQdhZGRyZXNzBQNrZXkJAQd3cmFwRXJyAQkArAICBQNrZXkC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dGluZ1Jld2FyZEFzc2V0SWQJAMwIAgkBDEludGVnZXJFbnRyeQIFD2NsYWltSGlzdG9yeUtleQUMcmV3YXJkQW1vdW50BQNuaWwJAQh0aHJvd0VycgECEG5vdGhpbmcgdG8gY2xhaW0FDHJld2FyZEFjdGlvbgkAAgECJFN0cmljdCB2YWx1ZSBpcyBub3QgZXF1YWwgdG8gaXRzZWxmLgECdHgBBnZlcmlmeQAED3RhcmdldFB1YmxpY0tleQQHJG1hdGNoMAkBFm1hbmFnZXJQdWJsaWNLZXlPclVuaXQAAwkAAQIFByRtYXRjaDACCkJ5dGVWZWN0b3IEAnBrBQckbWF0Y2gwBQJwawMJAAECBQckbWF0Y2gwAgRVbml0CAUCdHgPc2VuZGVyUHVibGljS2V5CQACAQILTWF0Y2ggZXJyb3IJAPQDAwgFAnR4CWJvZHlCeXRlcwkAkQMCCAUCdHgGcHJvb2ZzAAAFD3RhcmdldFB1YmxpY0tleZtvPxI=", "height": 2605117, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 5sBtdFLYPfixMZ2Y4UB5CSPpDvH5hypwro9AtRBeCbbp Next: 8Pfv3ze8PfRA7ShnNi5oSAMpmowyp7Ke8QP2jPMHWfig Diff:
OldNewDifferences
7777 func keyVotingRewardAssetId (assetId,index) = makeString(["%s%s%d", "votingRewardAssetId", assetId, toString(index)], separator)
7878
7979
80+func keyVotingReward (userAddress,assetId,index) = makeString(["%s%s%s%d", "votingReward", toString(userAddress), assetId, toString(index)], separator)
81+
82+
8083 func keyTotalVotingReward (assetId,index) = makeString(["%s%s%d", "votingReward", assetId, toString(index)], separator)
8184
8285
105108
106109
107110 func keyClaimHistory (userAddress,assetId,index) = makeString(["%s%s%s%d", "history", toString(userAddress), assetId, toString(index)], separator)
108-
109-
110-func claimHistoryValue (gwxAmount) = makeString(["%d%s", toString(gwxAmount)], separator)
111111
112112
113113 func keyVotingEndHeight (assetId,index) = makeString(["%s%s%d", "votingEndHeight", assetId, toString(index)], separator)
306306 let newVotingValue = if (inFavor)
307307 then votingValue((parseIntValue(lastVotingValueParts[1]) + gwxAmountAtEnd), parseIntValue(lastVotingValueParts[2]))
308308 else votingValue(parseIntValue(lastVotingValueParts[1]), (parseIntValue(lastVotingValueParts[2]) + gwxAmountAtEnd))
309-[StringEntry(voteKey, voteValue(inFavor, gwxAmountAtEnd)), StringEntry(votingResultKey, newVotingValue)]
309+[StringEntry(voteKey, voteValue(inFavor, gwxAmountAtEnd)), StringEntry(votingResultKey, newVotingValue), BooleanEntry(keyVotingReward(i.caller, assetId, currentIndex), true)]
310310 }
311311 else throw("Strict value is not equal to itself.")
312312 }
340340 let newVotingResultValue = if ((inFavor == "true"))
341341 then votingValue((parseIntValue(lastVotingValueParts[1]) - gwxAmount), parseIntValue(lastVotingValueParts[2]))
342342 else votingValue(parseIntValue(lastVotingValueParts[1]), (parseIntValue(lastVotingValueParts[2]) - gwxAmount))
343-[DeleteEntry(voteKey), StringEntry(votingResultKey, newVotingResultValue)]
343+[DeleteEntry(voteKey), StringEntry(votingResultKey, newVotingResultValue), DeleteEntry(keyVotingReward(i.caller, assetId, currentIndex))]
344344 }
345345 else throw("Strict value is not equal to itself.")
346346 }
357357 let currentIndex = valueOrElse(getInteger(currentIndexKey), 0)
358358 let votingThresholdAdd = valueOrErrorMessage(getInteger(keyVotingThresholdAdd), wrapErr("votingThresholdAdd not set"))
359359 let votingThresholdRemove = valueOrErrorMessage(getInteger(keyVotingThresholdRemove), wrapErr("votingThresholdRemove not set"))
360- let $t01478315222 = if (verificationInProgress)
360+ let $t01501215451 = if (verificationInProgress)
361361 then $Tuple3([DeleteEntry(keyVerificationInProgress(assetId)), BooleanEntry(keyVerified(assetId), true)], true, votingThresholdAdd)
362362 else $Tuple3([DeleteEntry(keyDeverificationInProgress(assetId)), DeleteEntry(keyVerified(assetId))], true, votingThresholdRemove)
363- let finalizeVotingActions = $t01478315222._1
364- let verified = $t01478315222._2
365- let threshold = $t01478315222._3
363+ let finalizeVotingActions = $t01501215451._1
364+ let verified = $t01501215451._2
365+ let threshold = $t01501215451._3
366366 let lastVotingValue = valueOrElse(getString(keyVotingResult(assetId, currentIndex)), defaultVotingValue)
367367 let lastVotingValueParts = split(lastVotingValue, separator)
368368 let votesFor = parseIntValue(lastVotingValueParts[1])
414414 func claim (assetId,index) = {
415415 let callerAddress = i.caller
416416 let claimHistoryKey = keyClaimHistory(callerAddress, assetId, index)
417- let claimHistory = getString(claimHistoryKey)
417+ let claimHistory = getInteger(claimHistoryKey)
418418 let checks = [if ((claimHistory == unit))
419419 then true
420420 else throwErr("already claimed")]
427427 let rewardAction = if (isDefined(votingRewardAssetIdStr))
428428 then {
429429 let votingRewardAssetId = fromBase58String(value(votingRewardAssetIdStr))
430-[ScriptTransfer(callerAddress, rewardAmount, votingRewardAssetId), StringEntry(claimHistoryKey, claimHistoryValue(rewardAmount))]
430+[ScriptTransfer(callerAddress, rewardAmount, votingRewardAssetId), IntegerEntry(claimHistoryKey, rewardAmount)]
431431 }
432432 else throwErr("nothing to claim")
433433 rewardAction
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let separator = "__"
55
66 let MULT8 = 100000000
77
88 func wrapErr (msg) = makeString(["voting_verified_v2.ride:", msg], " ")
99
1010
1111 func throwErr (msg) = throw(wrapErr(msg))
1212
1313
1414 func asInt (val) = match val {
1515 case valInt: Int =>
1616 valInt
1717 case _ =>
1818 throw("Failed to cast into Integer")
1919 }
2020
2121
2222 func getIntegerOrZero (address,key) = valueOrElse(getInteger(address, key), 0)
2323
2424
2525 func getIntegerOrFail (address,key) = valueOrErrorMessage(getInteger(address, key), wrapErr((key + " is not defined")))
2626
2727
2828 func getStringOrEmpty (address,key) = valueOrElse(getString(address, key), "")
2929
3030
3131 func getStringOrFail (address,key) = valueOrErrorMessage(getString(address, key), wrapErr((key + " is not defined")))
3232
3333
3434 let keyBoostingContract = makeString(["%s", "boostingContract"], separator)
3535
3636 let keyEmissionContract = makeString(["%s", "emissionContract"], separator)
3737
3838 let keyAssetsStoreContract = makeString(["%s", "assetsStoreContract"], separator)
3939
4040 let boostingContract = addressFromStringValue(getStringValue(keyBoostingContract))
4141
4242 let emissionContract = addressFromStringValue(getStringValue(keyEmissionContract))
4343
4444 let assetsStoreContract = addressFromStringValue(getStringValue(keyAssetsStoreContract))
4545
4646 let keyEmissionConfig = makeString(["%s", "config"], separator)
4747
4848 let wxAssetIdStr = split(getStringOrFail(emissionContract, keyEmissionConfig), separator)[1]
4949
5050 let wxAssetId = fromBase58String(wxAssetIdStr)
5151
5252 let keyVotingThresholdAdd = makeString(["%s%s", "votingThreshold", "add"], separator)
5353
5454 let keyVotingThresholdRemove = makeString(["%s%s", "votingThreshold", "remove"], separator)
5555
5656 func keyPeriodLengthAdd (assetId,index) = makeString(["%s%s%d", "periodLengthAdd", assetId, toString(index)], separator)
5757
5858
5959 let keyPeriodLengthRemove = makeString(["%s", "periodLengthRemove"], separator)
6060
6161 func keyCurrentVotingHeightStart (assetId,index) = makeString(["%s%s%d", "currentVotingHeightStart", assetId, toString(index)], separator)
6262
6363
6464 func keyVerified (assetId) = makeString(["%s%s", "verified", assetId], separator)
6565
6666
6767 func keyVerificationInProgress (assetId) = makeString(["%s%s%s", "verification", "inProgress", assetId], separator)
6868
6969
7070 func keyDeverificationInProgress (assetId) = makeString(["%s%s%s", "deverification", "inProgress", assetId], separator)
7171
7272
7373 let keyMaxPeriodLength = makeString(["%s", "maxPeriodLength"], separator)
7474
7575 let keyMinPeriodLength = makeString(["%s", "minPeriodLength"], separator)
7676
7777 func keyVotingRewardAssetId (assetId,index) = makeString(["%s%s%d", "votingRewardAssetId", assetId, toString(index)], separator)
7878
7979
80+func keyVotingReward (userAddress,assetId,index) = makeString(["%s%s%s%d", "votingReward", toString(userAddress), assetId, toString(index)], separator)
81+
82+
8083 func keyTotalVotingReward (assetId,index) = makeString(["%s%s%d", "votingReward", assetId, toString(index)], separator)
8184
8285
8386 let keyFinalizeCallRewardAmount = makeString(["%s", "finalizeCallRewardAmount"], separator)
8487
8588 let keyMinSuggestRemoveBalance = makeString(["%s", "minSuggestRemoveBalance"], separator)
8689
8790 func keyCurrentIndex (assetId) = makeString(["%s%s", "currentIndex", assetId], separator)
8891
8992
9093 func keyVote (assetId,index,caller) = makeString(["%s%s%d%s", "vote", assetId, toString(index), toString(caller)], separator)
9194
9295
9396 func voteValue (inFavor,gwxAmount) = makeString(["%s%d", toString(inFavor), toString(gwxAmount)], separator)
9497
9598
9699 func keyVotingResult (assetId,index) = makeString(["%s%s%d", "votingResult", assetId, toString(index)], separator)
97100
98101
99102 func votingValue (forAmount,againstAmount) = makeString(["%d%d", toString(forAmount), toString(againstAmount)], separator)
100103
101104
102105 let defaultVotingValue = makeString(["%d%d", "0", "0"], separator)
103106
104107 func keySuggestIssuer (assetId,index) = makeString(["%s%s%d", "suggestIssuer", assetId, toString(index)], separator)
105108
106109
107110 func keyClaimHistory (userAddress,assetId,index) = makeString(["%s%s%s%d", "history", toString(userAddress), assetId, toString(index)], separator)
108-
109-
110-func claimHistoryValue (gwxAmount) = makeString(["%d%s", toString(gwxAmount)], separator)
111111
112112
113113 func keyVotingEndHeight (assetId,index) = makeString(["%s%s%d", "votingEndHeight", assetId, toString(index)], separator)
114114
115115
116116 let keyFeePerBlock = makeString(["%s", "feePerBlock"], separator)
117117
118118 let feePerBlock = getIntegerOrFail(this, keyFeePerBlock)
119119
120120 let keyMinWxMinForSuggestAddAmountRequired = makeString(["%s", "wxMinForSuggestAddAmountRequired"], separator)
121121
122122 let keyWxForSuggestRemoveAmountRequired = makeString(["%s", "wxForSuggestRemoveAmountRequired"], separator)
123123
124124 func getUserGwxAmountAtHeight (userAddress,targetHeight) = {
125125 let gwxAmount = invoke(boostingContract, "getUserGwxAmountAtHeightREADONLY", [userAddress, targetHeight], nil)
126126 asInt(gwxAmount)
127127 }
128128
129129
130130 func keyManagerVaultAddress () = "%s__managerVaultAddress"
131131
132132
133133 func keyManagerPublicKey () = "%s__managerPublicKey"
134134
135135
136136 func getManagerVaultAddressOrThis () = match getString(keyManagerVaultAddress()) {
137137 case s: String =>
138138 addressFromStringValue(s)
139139 case _ =>
140140 this
141141 }
142142
143143
144144 func managerPublicKeyOrUnit () = {
145145 let managerVaultAddress = getManagerVaultAddressOrThis()
146146 match getString(managerVaultAddress, keyManagerPublicKey()) {
147147 case s: String =>
148148 fromBase58String(s)
149149 case _: Unit =>
150150 unit
151151 case _ =>
152152 throw("Match error")
153153 }
154154 }
155155
156156
157157 func votingExistChecks (assetId,currentIndex) = {
158158 let verificationInProgress = valueOrElse(getBoolean(keyVerificationInProgress(assetId)), false)
159159 let deverificationInProgress = valueOrElse(getBoolean(keyDeverificationInProgress(assetId)), false)
160160 let suggestIssuer = valueOrErrorMessage(getString(keySuggestIssuer(assetId, currentIndex)), wrapErr("voting issuer not found"))
161161 let currentVotingHeightStart = valueOrErrorMessage(getInteger(keyCurrentVotingHeightStart(assetId, currentIndex)), wrapErr("voting start height not found"))
162162 let votingPeriodLenght = if (verificationInProgress)
163163 then valueOrErrorMessage(getInteger(keyPeriodLengthAdd(assetId, currentIndex)), wrapErr("voting period length not found"))
164164 else value(getInteger(keyPeriodLengthRemove))
165165 let checks = [if (if (verificationInProgress)
166166 then true
167167 else deverificationInProgress)
168168 then true
169169 else throwErr("no voting in progress"), if (((currentVotingHeightStart + votingPeriodLenght) > height))
170170 then true
171171 else throwErr("voting expired")]
172172 if ((checks == checks))
173173 then $Tuple5(verificationInProgress, deverificationInProgress, currentVotingHeightStart, votingPeriodLenght, suggestIssuer)
174174 else throw("Strict value is not equal to itself.")
175175 }
176176
177177
178178 func calculateReward (voter,assetId,index) = {
179179 let voteKey = keyVote(assetId, index, voter)
180180 let lastVote = valueOrErrorMessage(getString(voteKey), wrapErr("you have not voted"))
181181 let lastVoteParts = split(lastVote, separator)
182182 let inFavor = lastVoteParts[1]
183183 let rewardAmount = if ((inFavor == "true"))
184184 then {
185185 let gwxAmount = parseIntValue(lastVoteParts[2])
186186 let lastVotingValue = valueOrErrorMessage(getString(keyVotingResult(assetId, index)), wrapErr("voting does not exist"))
187187 let lastVotingValueParts = split(lastVotingValue, separator)
188188 let totalVotesFor = parseIntValue(lastVotingValueParts[1])
189189 let partOfTheTotalVotesX8 = fraction(gwxAmount, MULT8, totalVotesFor)
190190 let totalVotingReward = valueOrElse(getInteger(keyTotalVotingReward(assetId, index)), 0)
191191 let rewardAmount = fraction(partOfTheTotalVotesX8, totalVotingReward, MULT8, FLOOR)
192192 rewardAmount
193193 }
194194 else 0
195195 rewardAmount
196196 }
197197
198198
199199 @Callable(i)
200200 func suggestAdd (assetId,periodLength,assetImage) = {
201201 let info = valueOrErrorMessage(assetInfo(fromBase58String(assetId)), "Invalid asset ID")
202202 if ((info == info))
203203 then {
204204 let currentIndexKey = keyCurrentIndex(assetId)
205205 let currentIndex = getInteger(currentIndexKey)
206206 let newIndex = if (isDefined(currentIndex))
207207 then (value(currentIndex) + 1)
208208 else 0
209209 let wxPayment = i.payments[0]
210210 let wxPaymentAssetId = value(wxPayment.assetId)
211211 let wxPaymentAmount = value(wxPayment.amount)
212212 let votingRewardActions = if ((size(i.payments) > 1))
213213 then {
214214 let votingRewardPayment = i.payments[1]
215215 let votingRewardPaymentAssetId = toBase58String(value(votingRewardPayment.assetId))
216216 let votingRewardPaymentAmount = value(votingRewardPayment.amount)
217217 [StringEntry(keyVotingRewardAssetId(assetId, newIndex), votingRewardPaymentAssetId), IntegerEntry(keyTotalVotingReward(assetId, newIndex), votingRewardPaymentAmount)]
218218 }
219219 else nil
220220 let minPeriodLength = getIntegerValue(keyMinPeriodLength)
221221 let maxPeriodLength = getIntegerValue(keyMaxPeriodLength)
222222 let checks = [if (if ((periodLength >= minPeriodLength))
223223 then (maxPeriodLength >= periodLength)
224224 else false)
225225 then true
226226 else throwErr("invalid periodLength"), if ((getBoolean(keyVerified(assetId)) == unit))
227227 then true
228228 else throwErr("already verified"), if ((getBoolean(keyVerificationInProgress(assetId)) == unit))
229229 then true
230230 else throwErr("already in progress"), if ((wxPaymentAmount > (periodLength * feePerBlock)))
231231 then true
232232 else throwErr("not enough wx for given period"), if ((wxPaymentAmount >= getIntegerValue(keyMinWxMinForSuggestAddAmountRequired)))
233233 then true
234234 else throwErr("payment less then min for suggest")]
235235 if ((checks == checks))
236236 then {
237237 let assetsStoreCreateOrUpdateInv = invoke(assetsStoreContract, "createOrUpdate", [assetId, assetImage, false], nil)
238238 if ((assetsStoreCreateOrUpdateInv == assetsStoreCreateOrUpdateInv))
239239 then {
240240 let votingEndHeight = (height + periodLength)
241241 let finalizeCallRewardAmount = valueOrElse(getInteger(keyFinalizeCallRewardAmount), 0)
242242 let burnWxAmount = (wxPaymentAmount - finalizeCallRewardAmount)
243243 ([IntegerEntry(currentIndexKey, newIndex), BooleanEntry(keyVerificationInProgress(assetId), true), IntegerEntry(keyCurrentVotingHeightStart(assetId, newIndex), height), IntegerEntry(keyPeriodLengthAdd(assetId, newIndex), periodLength), StringEntry(keySuggestIssuer(assetId, newIndex), toString(i.caller)), IntegerEntry(keyVotingEndHeight(assetId, newIndex), votingEndHeight), Burn(wxPaymentAssetId, burnWxAmount)] ++ votingRewardActions)
244244 }
245245 else throw("Strict value is not equal to itself.")
246246 }
247247 else throw("Strict value is not equal to itself.")
248248 }
249249 else throw("Strict value is not equal to itself.")
250250 }
251251
252252
253253
254254 @Callable(i)
255255 func suggestRemove (assetId) = {
256256 let gwxAmountAtNow = getUserGwxAmountAtHeight(toString(i.caller), height)
257257 let minSuggestRemoveBalance = getIntegerValue(keyMinSuggestRemoveBalance)
258258 let wxPayment = i.payments[0]
259259 let wxPaymentAssetId = value(wxPayment.assetId)
260260 let wxPaymentAmount = value(wxPayment.amount)
261261 let isVerified = valueOrElse(getBoolean(keyVerified(assetId)), false)
262262 let checks = [if (isVerified)
263263 then true
264264 else throwErr(makeString([assetId, "not verified"], " ")), if ((gwxAmountAtNow >= minSuggestRemoveBalance))
265265 then true
266266 else throwErr("not enough gWXes"), if ((wxPaymentAmount >= getIntegerValue(keyWxForSuggestRemoveAmountRequired)))
267267 then true
268268 else throwErr("payment less then min for suggest")]
269269 if ((checks == checks))
270270 then {
271271 let currentIndexKey = keyCurrentIndex(assetId)
272272 let currentIndex = getInteger(currentIndexKey)
273273 let newIndex = if (isDefined(currentIndex))
274274 then (value(currentIndex) + 1)
275275 else 0
276276 let periodLength = valueOrErrorMessage(getInteger(keyPeriodLengthRemove), wrapErr("periodLengthRemove not set"))
277277 let votingEndHeight = (height + periodLength)
278278 [IntegerEntry(currentIndexKey, newIndex), BooleanEntry(keyDeverificationInProgress(assetId), true), IntegerEntry(keyCurrentVotingHeightStart(assetId, newIndex), height), StringEntry(keySuggestIssuer(assetId, newIndex), toString(i.caller)), IntegerEntry(keyVotingEndHeight(assetId, newIndex), votingEndHeight)]
279279 }
280280 else throw("Strict value is not equal to itself.")
281281 }
282282
283283
284284
285285 @Callable(i)
286286 func vote (assetId,inFavor) = {
287287 let currentIndexKey = keyCurrentIndex(assetId)
288288 let currentIndex = valueOrErrorMessage(getInteger(currentIndexKey), wrapErr("voting does not exist"))
289289 let votingInfo = votingExistChecks(assetId, currentIndex)
290290 if ((votingInfo == votingInfo))
291291 then {
292292 let currentVotingHeightStart = votingInfo._3
293293 let votingPeriodLenght = votingInfo._4
294294 let gwxAmountAtEnd = getUserGwxAmountAtHeight(toString(i.caller), (currentVotingHeightStart + votingPeriodLenght))
295295 let voteKey = keyVote(assetId, currentIndex, i.caller)
296296 let votingResultKey = keyVotingResult(assetId, currentIndex)
297297 let checks = [if ((getString(voteKey) == unit))
298298 then true
299299 else throwErr("You have already voted"), if ((gwxAmountAtEnd > 0))
300300 then true
301301 else throw("You'll not have gWX at the end of voting")]
302302 if ((checks == checks))
303303 then {
304304 let lastVotingValue = valueOrElse(getString(votingResultKey), defaultVotingValue)
305305 let lastVotingValueParts = split(lastVotingValue, separator)
306306 let newVotingValue = if (inFavor)
307307 then votingValue((parseIntValue(lastVotingValueParts[1]) + gwxAmountAtEnd), parseIntValue(lastVotingValueParts[2]))
308308 else votingValue(parseIntValue(lastVotingValueParts[1]), (parseIntValue(lastVotingValueParts[2]) + gwxAmountAtEnd))
309-[StringEntry(voteKey, voteValue(inFavor, gwxAmountAtEnd)), StringEntry(votingResultKey, newVotingValue)]
309+[StringEntry(voteKey, voteValue(inFavor, gwxAmountAtEnd)), StringEntry(votingResultKey, newVotingValue), BooleanEntry(keyVotingReward(i.caller, assetId, currentIndex), true)]
310310 }
311311 else throw("Strict value is not equal to itself.")
312312 }
313313 else throw("Strict value is not equal to itself.")
314314 }
315315
316316
317317
318318 @Callable(i)
319319 func cancelVote (assetId) = {
320320 let currentIndexKey = keyCurrentIndex(assetId)
321321 let currentIndex = valueOrErrorMessage(getInteger(currentIndexKey), wrapErr("voting does not exist"))
322322 let voteKey = keyVote(assetId, currentIndex, i.caller)
323323 let votingResultKey = keyVotingResult(assetId, currentIndex)
324324 let lastVote = valueOrErrorMessage(getString(voteKey), wrapErr("you have not voted"))
325325 let lastVoteParts = split(lastVote, separator)
326326 let inFavor = lastVoteParts[1]
327327 let gwxAmount = parseIntValue(lastVoteParts[2])
328328 let votingInfo = votingExistChecks(assetId, currentIndex)
329329 if ((votingInfo == votingInfo))
330330 then {
331331 let checks = [if (if ((inFavor == "true"))
332332 then true
333333 else (inFavor == "false"))
334334 then true
335335 else throwErr("invalid vote")]
336336 if ((checks == checks))
337337 then {
338338 let lastVotingValue = valueOrElse(getString(votingResultKey), defaultVotingValue)
339339 let lastVotingValueParts = split(lastVotingValue, separator)
340340 let newVotingResultValue = if ((inFavor == "true"))
341341 then votingValue((parseIntValue(lastVotingValueParts[1]) - gwxAmount), parseIntValue(lastVotingValueParts[2]))
342342 else votingValue(parseIntValue(lastVotingValueParts[1]), (parseIntValue(lastVotingValueParts[2]) - gwxAmount))
343-[DeleteEntry(voteKey), StringEntry(votingResultKey, newVotingResultValue)]
343+[DeleteEntry(voteKey), StringEntry(votingResultKey, newVotingResultValue), DeleteEntry(keyVotingReward(i.caller, assetId, currentIndex))]
344344 }
345345 else throw("Strict value is not equal to itself.")
346346 }
347347 else throw("Strict value is not equal to itself.")
348348 }
349349
350350
351351
352352 @Callable(i)
353353 func finalize (assetId) = {
354354 let verificationInProgress = valueOrElse(getBoolean(keyVerificationInProgress(assetId)), false)
355355 let deverificationInProgress = valueOrElse(getBoolean(keyDeverificationInProgress(assetId)), false)
356356 let currentIndexKey = keyCurrentIndex(assetId)
357357 let currentIndex = valueOrElse(getInteger(currentIndexKey), 0)
358358 let votingThresholdAdd = valueOrErrorMessage(getInteger(keyVotingThresholdAdd), wrapErr("votingThresholdAdd not set"))
359359 let votingThresholdRemove = valueOrErrorMessage(getInteger(keyVotingThresholdRemove), wrapErr("votingThresholdRemove not set"))
360- let $t01478315222 = if (verificationInProgress)
360+ let $t01501215451 = if (verificationInProgress)
361361 then $Tuple3([DeleteEntry(keyVerificationInProgress(assetId)), BooleanEntry(keyVerified(assetId), true)], true, votingThresholdAdd)
362362 else $Tuple3([DeleteEntry(keyDeverificationInProgress(assetId)), DeleteEntry(keyVerified(assetId))], true, votingThresholdRemove)
363- let finalizeVotingActions = $t01478315222._1
364- let verified = $t01478315222._2
365- let threshold = $t01478315222._3
363+ let finalizeVotingActions = $t01501215451._1
364+ let verified = $t01501215451._2
365+ let threshold = $t01501215451._3
366366 let lastVotingValue = valueOrElse(getString(keyVotingResult(assetId, currentIndex)), defaultVotingValue)
367367 let lastVotingValueParts = split(lastVotingValue, separator)
368368 let votesFor = parseIntValue(lastVotingValueParts[1])
369369 let votesAgainst = parseIntValue(lastVotingValueParts[2])
370370 let votesTotal = (votesFor + votesAgainst)
371371 let votingEndHeight = valueOrErrorMessage(getInteger(keyVotingEndHeight(assetId, currentIndex)), wrapErr("voting end height not found"))
372372 let checks = [if (if (verificationInProgress)
373373 then true
374374 else deverificationInProgress)
375375 then true
376376 else throwErr("nothing to finalize"), if ((height >= votingEndHeight))
377377 then true
378378 else throwErr("voting not finished"), if ((votesTotal >= threshold))
379379 then true
380380 else throwErr("not enough votes")]
381381 if ((checks == checks))
382382 then {
383383 let finalizeCallRewardAction = if ((votesAgainst > votesFor))
384384 then {
385385 let setVerifiedInvoke = invoke(assetsStoreContract, "setVerified", [assetId, verified], nil)
386386 if ((setVerifiedInvoke == setVerifiedInvoke))
387387 then {
388388 let finalizeCallRewardAmount = valueOrElse(getInteger(keyFinalizeCallRewardAmount), 0)
389389 [ScriptTransfer(i.caller, finalizeCallRewardAmount, wxAssetId)]
390390 }
391391 else throw("Strict value is not equal to itself.")
392392 }
393393 else nil
394394 (finalizeVotingActions ++ finalizeCallRewardAction)
395395 }
396396 else throw("Strict value is not equal to itself.")
397397 }
398398
399399
400400
401401 @Callable(i)
402402 func claimREADONLY (assetId,index) = {
403403 let callerAddress = i.caller
404404 let votingRewardAssetIdStr = getString(keyVotingRewardAssetId(assetId, index))
405405 let rewardAmount = if (isDefined(votingRewardAssetIdStr))
406406 then calculateReward(callerAddress, assetId, index)
407407 else 0
408408 $Tuple2(nil, rewardAmount)
409409 }
410410
411411
412412
413413 @Callable(i)
414414 func claim (assetId,index) = {
415415 let callerAddress = i.caller
416416 let claimHistoryKey = keyClaimHistory(callerAddress, assetId, index)
417- let claimHistory = getString(claimHistoryKey)
417+ let claimHistory = getInteger(claimHistoryKey)
418418 let checks = [if ((claimHistory == unit))
419419 then true
420420 else throwErr("already claimed")]
421421 if ((checks == checks))
422422 then {
423423 let rewardAmount = if ((calculateReward(callerAddress, assetId, index) > 0))
424424 then calculateReward(callerAddress, assetId, index)
425425 else throwErr("nothing to claim")
426426 let votingRewardAssetIdStr = getString(keyVotingRewardAssetId(assetId, index))
427427 let rewardAction = if (isDefined(votingRewardAssetIdStr))
428428 then {
429429 let votingRewardAssetId = fromBase58String(value(votingRewardAssetIdStr))
430-[ScriptTransfer(callerAddress, rewardAmount, votingRewardAssetId), StringEntry(claimHistoryKey, claimHistoryValue(rewardAmount))]
430+[ScriptTransfer(callerAddress, rewardAmount, votingRewardAssetId), IntegerEntry(claimHistoryKey, rewardAmount)]
431431 }
432432 else throwErr("nothing to claim")
433433 rewardAction
434434 }
435435 else throw("Strict value is not equal to itself.")
436436 }
437437
438438
439439 @Verifier(tx)
440440 func verify () = {
441441 let targetPublicKey = match managerPublicKeyOrUnit() {
442442 case pk: ByteVector =>
443443 pk
444444 case _: Unit =>
445445 tx.senderPublicKey
446446 case _ =>
447447 throw("Match error")
448448 }
449449 sigVerify(tx.bodyBytes, tx.proofs[0], targetPublicKey)
450450 }
451451

github/deemru/w8io/169f3d6 
56.55 ms