tx · 66aDmYgExJDGMj1nKA9pEAZrpsf6rqFUCGu9cuCFQdHj

3N1Epwa6GQuTQr2K9WzeUcqSFCdERwuvL5T:  -0.01400000 Waves

2022.05.06 15:03 [2039814] smart account 3N1Epwa6GQuTQr2K9WzeUcqSFCdERwuvL5T > SELF 0.00000000 Waves

{ "type": 13, "id": "66aDmYgExJDGMj1nKA9pEAZrpsf6rqFUCGu9cuCFQdHj", "fee": 1400000, "feeAssetId": null, "timestamp": 1651838621644, "version": 1, "sender": "3N1Epwa6GQuTQr2K9WzeUcqSFCdERwuvL5T", "senderPublicKey": "7iXEgsFNsnbLZ3ca4tmz8jffnyxMu9keuBV6CuQPJLuA", "proofs": [ "3KriyuhbyKiomQ45AEZVtKyXoapReX6rh8Xu1iFMtz9X2WwVbNxELfbqXGPere6PtyhtSdd5HPcSpxvjdwYHhoJF" ], "script": "base64:AAIFAAAAAAAAADoIAhIMCgoICAgIAQgBAQgBEgQKAggIEgUKAwgIBBIECgIICBIDCgEBEgMKAQESBAoCCAgSAwoBCBIAAAAAGwAAAAAJc2VwYXJhdG9yAgAAAAJfXwAAAAAMa2V5RmVlQW1vdW50CQAEuQAAAAIJAARMAAAAAgIAAAACJXMJAARMAAAAAgIAAAADZmVlBQAAAANuaWwFAAAACXNlcGFyYXRvcgAAAAAOa2V5VXNkbkFzc2V0SWQJAAS5AAAAAgkABEwAAAACAgAAAAIlcwkABEwAAAACAgAAAAt1c2RuQXNzZXRJZAUAAAADbmlsBQAAAAlzZXBhcmF0b3IAAAAAEWtleVZvdGluZ0R1cmF0aW9uCQAEuQAAAAIJAARMAAAAAgIAAAACJXMJAARMAAAAAgIAAAALZXBvY2hMZW5ndGgFAAAAA25pbAUAAAAJc2VwYXJhdG9yAAAAABFrZXlGaW5hbGl6ZVJld2FyZAkABLkAAAACCQAETAAAAAICAAAAAiVzCQAETAAAAAICAAAADmZpbmFsaXplUmV3YXJkBQAAAANuaWwFAAAACXNlcGFyYXRvcgAAAAASa2V5Vm90aW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EFAAAAAnBtCQAETAAAAAIJAQAAAAtEZWxldGVFbnRyeQAAAAEJAQAAABprZXlQZW5kaW5nTWFuYWdlclB1YmxpY0tleQAAAAAFAAAAA25pbAkAAAIAAAABAgAAACRTdHJpY3QgdmFsdWUgaXMgbm90IGVxdWFsIHRvIGl0c2VsZi4JAAACAAAAAQIAAAAkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuAAAAAQAAAAJ0eAEAAAAGdmVyaWZ5AAAAAAQAAAAPdGFyZ2V0UHVibGljS2V5BAAAAAckbWF0Y2gwCQEAAAAWbWFuYWdlclB1YmxpY0tleU9yVW5pdAAAAAADCQAAAQAAAAIFAAAAByRtYXRjaDACAAAACkJ5dGVWZWN0b3IEAAAAAnBrBQAAAAckbWF0Y2gwBQAAAAJwawMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAEVW5pdAgFAAAAAnR4AAAAD3NlbmRlclB1YmxpY0tleQkAAAIAAAABAgAAAAtNYXRjaCBlcnJvcgkAAfQAAAADCAUAAAACdHgAAAAJYm9keUJ5dGVzCQABkQAAAAIIBQAAAAJ0eAAAAAZwcm9vZnMAAAAAAAAAAAAFAAAAD3RhcmdldFB1YmxpY0tleYf36zo=", "chainId": 84, "height": 2039814, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 9vHL7r6M9ndfd8VKh1tFWGn3LPm3pCoMpHG6mo8JoZy5 Next: 6fRp6dfcnfwgf5DffwywYQMKBLaTAFZhu8XDARq31cGD Diff:
OldNewDifferences
107107
108108 @Callable(i)
109109 func constructor (assetsStoreContractPrm,userPoolContractPrm,boostingContractPrm,emissionContractPrm,feeAmountPrm,wxAssetIdPrm,votingThresholdPrm,votingDurationPrm,usdnAssetIdPrm,finalizeRewardPrm) = {
110- let checks = [if (mustManager(i))
111- then true
112- else throw("Must manager"), if (isDefined(addressFromString(assetsStoreContractPrm)))
110+ let checks = [mustManager(i), if (isDefined(addressFromString(assetsStoreContractPrm)))
113111 then true
114112 else throw("Invalid asset_store contract address"), if (isDefined(addressFromString(boostingContractPrm)))
115113 then true
166164 }
167165 if ((ensureActive == ensureActive))
168166 then {
169- let ensureAmountAssetVerified = match invoke(value(addressFromString(keyAssetsStoreContract)), "isVerifiedREADONLY", [amountAssetId], nil) {
167+ let ensureAmountAssetVerified = match invoke(assetStoreContract, "isVerifiedREADONLY", [amountAssetId], nil) {
170168 case b: Boolean =>
171169 b
172170 case _ =>
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let separator = "__"
55
66 let keyFeeAmount = makeString(["%s", "fee"], separator)
77
88 let keyUsdnAssetId = makeString(["%s", "usdnAssetId"], separator)
99
1010 let keyVotingDuration = makeString(["%s", "epochLength"], separator)
1111
1212 let keyFinalizeReward = makeString(["%s", "finalizeReward"], separator)
1313
1414 let keyVotingThreshold = makeString(["%s", "votingThreshold"], separator)
1515
1616 let keyWxAssetId = makeString(["%s", "wxAssetId"], separator)
1717
1818 let keyAssetsStoreContract = makeString(["%s", "assetsStoreContract"], separator)
1919
2020 let keyuserPoolContract = makeString(["%s", "userPoolContract"], separator)
2121
2222 let keyEmissionContract = makeString(["%s", "emissionContract"], separator)
2323
2424 let keyBoostingContract = makeString(["%s", "boostingContract"], separator)
2525
2626 func getStringOrFail (key) = valueOrErrorMessage(getString(this, key), (key + " is not defined"))
2727
2828
2929 func keyInListAssetId (amountAssetId,priceAssetId) = makeString([("%s%s%s" + "inList"), amountAssetId, priceAssetId], separator)
3030
3131
3232 func keyStartHeight (amountAssetId,priceAssetId) = makeString([("%s%s%s" + "startHeight"), amountAssetId, priceAssetId], separator)
3333
3434
3535 func keyVotingResult (amountAssetId,priceAssetId) = makeString(["%s%s%s", "votingResult", amountAssetId, priceAssetId], separator)
3636
3737
3838 func keyVote (amountAssetId,priceAssetId,voterAddress) = makeString(["%s%s%s%s", "vote", amountAssetId, priceAssetId, voterAddress], separator)
3939
4040
4141 func keyVoteValue (gwxAmount,vote) = {
4242 let key = if (vote)
4343 then makeString(["%d%s", gwxAmount, "yes"], separator)
4444 else makeString(["%d%s", gwxAmount, "no"], separator)
4545 key
4646 }
4747
4848
4949 func keyManagerPublicKey () = "%s__managerPublicKey"
5050
5151
5252 func keyPendingManagerPublicKey () = "%s__pendingManagerPublicKey"
5353
5454
5555 let emissionContract = addressFromStringValue(getStringOrFail(keyEmissionContract))
5656
5757 let userPoolContract = addressFromStringValue(getStringOrFail(keyuserPoolContract))
5858
5959 let boostingContract = addressFromStringValue(getStringOrFail(keyBoostingContract))
6060
6161 let assetStoreContract = addressFromStringValue(getStringOrFail(keyAssetsStoreContract))
6262
6363 func managerPublicKeyOrUnit () = match getString(keyManagerPublicKey()) {
6464 case s: String =>
6565 fromBase58String(s)
6666 case _: Unit =>
6767 unit
6868 case _ =>
6969 throw("Match error")
7070 }
7171
7272
7373 func pendingManagerPublicKeyOrUnit () = match getString(keyPendingManagerPublicKey()) {
7474 case s: String =>
7575 fromBase58String(s)
7676 case _: Unit =>
7777 unit
7878 case _ =>
7979 throw("Match error")
8080 }
8181
8282
8383 func mustManager (i) = {
8484 let pd = throw("Permission denied")
8585 match managerPublicKeyOrUnit() {
8686 case pk: ByteVector =>
8787 if ((i.callerPublicKey == pk))
8888 then true
8989 else pd
9090 case _: Unit =>
9191 if ((i.caller == this))
9292 then true
9393 else pd
9494 case _ =>
9595 throw("Match error")
9696 }
9797 }
9898
9999
100100 func asInt (val) = match val {
101101 case valInt: Int =>
102102 valInt
103103 case _ =>
104104 throw("Failed to cast into Integer")
105105 }
106106
107107
108108 @Callable(i)
109109 func constructor (assetsStoreContractPrm,userPoolContractPrm,boostingContractPrm,emissionContractPrm,feeAmountPrm,wxAssetIdPrm,votingThresholdPrm,votingDurationPrm,usdnAssetIdPrm,finalizeRewardPrm) = {
110- let checks = [if (mustManager(i))
111- then true
112- else throw("Must manager"), if (isDefined(addressFromString(assetsStoreContractPrm)))
110+ let checks = [mustManager(i), if (isDefined(addressFromString(assetsStoreContractPrm)))
113111 then true
114112 else throw("Invalid asset_store contract address"), if (isDefined(addressFromString(boostingContractPrm)))
115113 then true
116114 else throw("Invalid boosting contract address"), if (isDefined(addressFromString(userPoolContractPrm)))
117115 then true
118116 else throw("Invalid user_pools contract address"), if (isDefined(addressFromString(emissionContractPrm)))
119117 then true
120118 else throw("Invalid emission contract address"), if ((feeAmountPrm >= 0))
121119 then true
122120 else throw("Invalid fee amount"), if ((votingDurationPrm > 0))
123121 then true
124122 else throw("Invalid voting duration"), if ((finalizeRewardPrm > 0))
125123 then true
126124 else throw("Invalid finalize reward"), if ((votingThresholdPrm >= 0))
127125 then true
128126 else throw("Invalid voting threshold"), if (isDefined(assetInfo(fromBase58String(wxAssetIdPrm))))
129127 then true
130128 else throw("Invalid WX asset ID"), if (isDefined(assetInfo(fromBase58String(usdnAssetIdPrm))))
131129 then true
132130 else throw("Invalid USDN asset ID")]
133131 if ((checks == checks))
134132 then $Tuple2([StringEntry(keyAssetsStoreContract, assetsStoreContractPrm), StringEntry(keyuserPoolContract, userPoolContractPrm), StringEntry(keyEmissionContract, emissionContractPrm), IntegerEntry(keyFeeAmount, feeAmountPrm), IntegerEntry(keyVotingDuration, votingDurationPrm), IntegerEntry(keyFinalizeReward, finalizeRewardPrm), IntegerEntry(keyVotingThreshold, votingThresholdPrm), StringEntry(keyWxAssetId, wxAssetIdPrm), StringEntry(keyUsdnAssetId, usdnAssetIdPrm)], unit)
135133 else throw("Strict value is not equal to itself.")
136134 }
137135
138136
139137
140138 @Callable(i)
141139 func suggest (amountAssetId,priceAssetId) = {
142140 let payment = value(i.payments[0])
143141 let info = valueOrErrorMessage(assetInfo(fromBase58String(amountAssetId)), "Invalid amountAssetId ID")
144142 let checks = [if ((info.issuer == i.caller))
145143 then true
146144 else throw("Asset can only be suggested by its issuer"), if ((info.scripted == false))
147145 then true
148146 else throw("Asset is smart"), if ((toBase58String(value(payment.assetId)) == value(getString(keyWxAssetId))))
149147 then true
150148 else throw("Invalid fee asset"), if ((payment.amount == value(getInteger(keyFeeAmount))))
151149 then true
152150 else throw("Invalid fee amount"), if ((priceAssetId == value(getString(keyUsdnAssetId))))
153151 then true
154152 else throw("priceAssetId is not USDN"), if ((getBoolean(keyInListAssetId(amountAssetId, priceAssetId)) == unit))
155153 then true
156154 else throw("Already in voting list")]
157155 if ((checks == checks))
158156 then {
159157 let ensureActive = match invoke(userPoolContract, "statusREADONLY", [amountAssetId, priceAssetId], nil) {
160158 case s: String =>
161159 if ((s == "active"))
162160 then true
163161 else throw("User pool is not active")
164162 case _ =>
165163 throw("User pool is not active")
166164 }
167165 if ((ensureActive == ensureActive))
168166 then {
169- let ensureAmountAssetVerified = match invoke(value(addressFromString(keyAssetsStoreContract)), "isVerifiedREADONLY", [amountAssetId], nil) {
167+ let ensureAmountAssetVerified = match invoke(assetStoreContract, "isVerifiedREADONLY", [amountAssetId], nil) {
170168 case b: Boolean =>
171169 b
172170 case _ =>
173171 throw("Asset is not verified")
174172 }
175173 if ((ensureAmountAssetVerified == ensureAmountAssetVerified))
176174 then {
177175 let burnFeeInv = invoke(emissionContract, "burn", nil, [AttachedPayment(payment.assetId, payment.amount)])
178176 if ((burnFeeInv == burnFeeInv))
179177 then [BooleanEntry(keyInListAssetId(amountAssetId, priceAssetId), true), IntegerEntry(keyStartHeight(amountAssetId, priceAssetId), height)]
180178 else throw("Strict value is not equal to itself.")
181179 }
182180 else throw("Strict value is not equal to itself.")
183181 }
184182 else throw("Strict value is not equal to itself.")
185183 }
186184 else throw("Strict value is not equal to itself.")
187185 }
188186
189187
190188
191189 @Callable(i)
192190 func vote (amountAssetId,priceAssetId,inFavor) = {
193191 let votingFinishHeight = (value(getInteger(keyStartHeight(amountAssetId, priceAssetId))) + value(getInteger(keyVotingDuration)))
194192 let checks = [if (valueOrElse(getBoolean(keyInListAssetId(amountAssetId, priceAssetId)), false))
195193 then true
196194 else throw("The token isn't on the voting list"), if ((height >= votingFinishHeight))
197195 then true
198196 else throw("too late to vote")]
199197 if ((checks == checks))
200198 then {
201199 let votingResult = split(value(getString(keyVotingResult(amountAssetId, priceAssetId))), separator)
202200 let positiveVotes = votingResult[1]
203201 let negativeVotes = votingResult[2]
204202 let gwxAmount = invoke(boostingContract, "getUserGwxAmountAtHeightREADONLY", [toString(i.caller), votingFinishHeight], nil)
205203 let entries = if (inFavor)
206204 then {
207205 let newPositiveVotes = (parseIntValue(positiveVotes) + asInt(gwxAmount))
208206 let totalVotes = makeString(["%d%d", toString(newPositiveVotes), negativeVotes], separator)
209207 let yesVoteKey = keyVote(amountAssetId, priceAssetId, toString(i.caller))
210208 let yesVoteValue = keyVoteValue(toString(asInt(gwxAmount)), inFavor)
211209 $Tuple2([StringEntry(keyVotingResult(amountAssetId, priceAssetId), totalVotes), StringEntry(yesVoteKey, yesVoteValue)], unit)
212210 }
213211 else {
214212 let newNegativeVotes = (parseIntValue(negativeVotes) + asInt(gwxAmount))
215213 let totalVotes = makeString(["%d%d", positiveVotes, toString(newNegativeVotes)], separator)
216214 let noVoteKey = keyVote(amountAssetId, priceAssetId, toString(i.caller))
217215 let noVoteValue = keyVoteValue(toString(asInt(gwxAmount)), inFavor)
218216 $Tuple2([StringEntry(keyVotingResult(amountAssetId, priceAssetId), totalVotes), StringEntry(noVoteKey, noVoteValue)], unit)
219217 }
220218 entries
221219 }
222220 else throw("Strict value is not equal to itself.")
223221 }
224222
225223
226224
227225 @Callable(i)
228226 func cancelVote (amountAssetId,priceAssetId) = {
229227 let checks = [if (isDefined(keyVotingResult(amountAssetId, priceAssetId)))
230228 then true
231229 else throw("No vote for assets pair")]
232230 if ((checks == checks))
233231 then {
234232 let vote = split(value(getString(keyVote(amountAssetId, priceAssetId, toString(i.caller)))), separator)
235233 let voteValue = vote[1]
236234 let voteType = vote[2]
237235 let votingResult = split(value(getString(keyVotingResult(amountAssetId, priceAssetId))), separator)
238236 let positiveVotes = votingResult[1]
239237 let negativeVotes = votingResult[2]
240238 let actions = if ((voteType == "yes"))
241239 then {
242240 let newPositiveVotes = (parseIntValue(positiveVotes) - parseIntValue(voteValue))
243241 let totalVotes = makeString(["%d%d", toString(newPositiveVotes), negativeVotes], separator)
244242 $Tuple2([StringEntry(keyVotingResult(amountAssetId, priceAssetId), totalVotes), DeleteEntry(keyVote(amountAssetId, priceAssetId, toString(i.caller)))], unit)
245243 }
246244 else {
247245 let newNegativeVotes = (parseIntValue(negativeVotes) - parseIntValue(voteValue))
248246 let totalVotes = makeString(["%d%d", toString(newNegativeVotes), negativeVotes], separator)
249247 $Tuple2([StringEntry(keyVotingResult(amountAssetId, priceAssetId), totalVotes), DeleteEntry(keyVote(amountAssetId, priceAssetId, toString(i.caller)))], unit)
250248 }
251249 actions
252250 }
253251 else throw("Strict value is not equal to itself.")
254252 }
255253
256254
257255
258256 @Callable(i)
259257 func setVotingThreshold (newThreshold) = {
260258 let checks = [if (mustManager(i))
261259 then true
262260 else throw("Must manager")]
263261 if ((checks == checks))
264262 then [IntegerEntry(keyVotingThreshold, newThreshold)]
265263 else throw("Strict value is not equal to itself.")
266264 }
267265
268266
269267
270268 @Callable(i)
271269 func setFee (newFee) = {
272270 let checks = [if (mustManager(i))
273271 then true
274272 else throw("Must manager")]
275273 if ((checks == checks))
276274 then [IntegerEntry(keyFeeAmount, newFee)]
277275 else throw("Strict value is not equal to itself.")
278276 }
279277
280278
281279
282280 @Callable(i)
283281 func finalize (amountAssetId,priceAssetId) = {
284282 let votingFinishHeight = (value(getInteger(keyStartHeight(amountAssetId, priceAssetId))) + value(getInteger(keyVotingDuration)))
285283 let checks = [if (isDefined(keyInListAssetId(amountAssetId, priceAssetId)))
286284 then true
287285 else throw("No assets pair"), if ((votingFinishHeight > height))
288286 then true
289287 else throw("insufficient height for completion")]
290288 if ((checks == checks))
291289 then {
292290 let votingResult = split(value(getString(keyVotingResult(amountAssetId, priceAssetId))), separator)
293291 let positiveVotes = parseIntValue(votingResult[1])
294292 let negativeVotes = parseIntValue(votingResult[2])
295293 let actions = if ((positiveVotes > negativeVotes))
296294 then {
297295 let res = invoke(assetStoreContract, "setPoolLabels", [amountAssetId, priceAssetId, "WX_EMISSION"], nil)
298296 if ((res == res))
299297 then $Tuple2([DeleteEntry(keyInListAssetId(amountAssetId, priceAssetId))], unit)
300298 else throw("Strict value is not equal to itself.")
301299 }
302300 else $Tuple2([DeleteEntry(keyInListAssetId(amountAssetId, priceAssetId))], unit)
303301 actions
304302 }
305303 else throw("Strict value is not equal to itself.")
306304 }
307305
308306
309307
310308 @Callable(i)
311309 func setManager (pendingManagerPublicKey) = {
312310 let checkCaller = mustManager(i)
313311 if ((checkCaller == checkCaller))
314312 then {
315313 let checkManagerPublicKey = fromBase58String(pendingManagerPublicKey)
316314 if ((checkManagerPublicKey == checkManagerPublicKey))
317315 then [StringEntry(keyPendingManagerPublicKey(), pendingManagerPublicKey)]
318316 else throw("Strict value is not equal to itself.")
319317 }
320318 else throw("Strict value is not equal to itself.")
321319 }
322320
323321
324322
325323 @Callable(i)
326324 func confirmManager () = {
327325 let pm = pendingManagerPublicKeyOrUnit()
328326 let hasPM = if (isDefined(pm))
329327 then true
330328 else throw("No pending manager")
331329 if ((hasPM == hasPM))
332330 then {
333331 let checkPM = if ((i.callerPublicKey == value(pm)))
334332 then true
335333 else throw("You are not pending manager")
336334 if ((checkPM == checkPM))
337335 then [StringEntry(keyManagerPublicKey(), toBase58String(value(pm))), DeleteEntry(keyPendingManagerPublicKey())]
338336 else throw("Strict value is not equal to itself.")
339337 }
340338 else throw("Strict value is not equal to itself.")
341339 }
342340
343341
344342 @Verifier(tx)
345343 func verify () = {
346344 let targetPublicKey = match managerPublicKeyOrUnit() {
347345 case pk: ByteVector =>
348346 pk
349347 case _: Unit =>
350348 tx.senderPublicKey
351349 case _ =>
352350 throw("Match error")
353351 }
354352 sigVerify(tx.bodyBytes, tx.proofs[0], targetPublicKey)
355353 }
356354

github/deemru/w8io/169f3d6 
46.91 ms