tx · 5Pe8ULrrAtZJzcNbgMb61V3WsVUoB9icGCM1GULWDXgB

3MrqFfv385KAzAqqdQyprR7FMLSapeifggB:  -0.01300000 Waves

2023.05.02 09:54 [2559810] smart account 3MrqFfv385KAzAqqdQyprR7FMLSapeifggB > SELF 0.00000000 Waves

{ "type": 13, "id": "5Pe8ULrrAtZJzcNbgMb61V3WsVUoB9icGCM1GULWDXgB", "fee": 1300000, "feeAssetId": null, "timestamp": 1683010453119, "version": 2, "chainId": 84, "sender": "3MrqFfv385KAzAqqdQyprR7FMLSapeifggB", "senderPublicKey": "8Tqc64F7G2nACr6yk8egBWCVAp9ZLxjTeWYdXoyQvMAN", "proofs": [ "5aBq6uXTDCVsZQ4KV5po5XCamWYiUPdpcLDrbR76JtoX6LXHn437k1w3QQe64twP412q66Xkn1te6msGHA8yUeqb" ], "script": "base64:BgIgCAISBgoECAgBARIECgIBBBIDCgEBEgQKAgEEEgMKAQESAANTRVACAl9fARBibG9ja0hlaWdodEVycm9yAAkAAgECL1RoZSBibG9jaydzIGhlaWdodCBpcyB0b28gYmlnIGZvciB0aGlzIHByb3Bvc2FsARBhbHJlYWR5Vm90ZUVycm9yAAkAAgECFllvdSBoYXZlIGFscmVhZHkgdm90ZWQBC25vVm90ZUVycm9yAAkAAgECGllvdSBoYXZlIG5vdCBhbHJlYWR5IHZvdGVkARJnd3hDb250cmFjdEFkZHJlc3MACQC5CQIJAMwIAgICJXMJAMwIAgISZ3d4Q29udHJhY3RBZGRyZXNzBQNuaWwFA1NFUAEPa2V5Q3VycmVudEluZGV4AAkAuQkCCQDMCAICAiVzCQDMCAICDGN1cnJlbnRJbmRleAUDbmlsBQNTRVABD2tleVByb3Bvc2FsSW5mbwEGbnVtYmVyCQC5CQIJAMwIAgIEJXMlZAkAzAgCAgxwcm9wb3NhbEluZm8JAMwIAgkApAMBBQZudW1iZXIFA25pbAUDU0VQARVrZXlVc2VyVm90ZU9uUHJvcG9zYWwCBm51bWJlcgR1c2VyCQC5CQIJA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iMHf Next: none Diff:
OldNewDifferences
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let SEP = "__"
5-
6-func keyManagerPublicKey () = "%s__managerPublicpKey"
7-
8-
9-func keyPendingManagerPublicKey () = "%s__pendingManagerPublicKey"
10-
115
126 func blockHeightError () = throw("The block's height is too big for this proposal")
137
3024 func keyUserVoteOnProposal (number,user) = makeString(["%s%d%s", "userVoteOnProposal", toString(number), user], SEP)
3125
3226
27+func keyManagerPublicKey () = "%s__managerPublicKey"
28+
29+
30+func keyManagerVaultAddress () = "%s__managerVaultAddress"
31+
32+
3333 func getCurrentIndex () = getIntegerValue(this, keyCurrentIndex())
34+
35+
36+func getManagerAddressOrFail () = addressFromStringValue(getStringValue(keyManagerVaultAddress()))
3437
3538
3639 func formatProposalInfo (name,description,end,quorumNumber,positiveVotes,negativeVotes) = makeString(["%d%d%d%d%d%d", name, description, end, quorumNumber, positiveVotes, negativeVotes], SEP)
4750 }
4851
4952
50-func managerPublicKeyOrUnit () = match getString(keyManagerPublicKey()) {
51- case s: String =>
52- fromBase58String(s)
53- case _: Unit =>
54- unit
55- case _ =>
56- throw("Match error")
57-}
58-
59-
60-func pendingManagerPublicKeyOrUnit () = match getString(keyPendingManagerPublicKey()) {
61- case s: String =>
62- fromBase58String(s)
63- case _: Unit =>
64- unit
65- case _ =>
66- throw("Match error")
67-}
53+func managerPublicKeyOrUnit () = {
54+ let managerVaultAddress = getManagerAddressOrFail()
55+ match getString(managerVaultAddress, keyManagerPublicKey()) {
56+ case s: String =>
57+ fromBase58String(s)
58+ case _: Unit =>
59+ unit
60+ case _ =>
61+ throw("Match error")
62+ }
63+ }
6864
6965
7066 func isManager (i) = match managerPublicKeyOrUnit() {
111107 if ((checks == checks))
112108 then {
113109 let gwxNumber = asInt(invoke(addressFromStringValue(getStringValue(gwxContractAddress())), "getUserGwxAmountAtHeightREADONLY", [toString(i.caller), value(parseInt(voteInfoArray[3]))], nil))
114- let $t033524440 = if (choice)
110+ let $t033714459 = if (choice)
115111 then {
116112 let action1 = StringEntry(keyProposalInfo(proposalIndex), formatProposalInfo(voteInfoArray[1], voteInfoArray[2], voteInfoArray[3], voteInfoArray[4], toString((value(parseInt(voteInfoArray[5])) + gwxNumber)), voteInfoArray[6]))
117113 let action2 = StringEntry(keyUserVoteOnProposal(proposalIndex, toString(i.caller)), formatUserVoteOnProposal("1", toString(gwxNumber)))
122118 let action2 = StringEntry(keyUserVoteOnProposal(proposalIndex, toString(i.caller)), formatUserVoteOnProposal("0", toString(gwxNumber)))
123119 $Tuple2(action1, action2)
124120 }
125- let action1 = $t033524440._1
126- let action2 = $t033524440._2
121+ let action1 = $t033714459._1
122+ let action2 = $t033714459._2
127123 [action1, action2]
128124 }
129125 else throw("Strict value is not equal to itself.")
174170 if ((checks == checks))
175171 then {
176172 let gwxNumber = asInt(invoke(addressFromStringValue(getStringValue(gwxContractAddress())), "getUserGwxAmountAtHeightREADONLY", [toString(i.caller), value(parseInt(voteInfoArray[3]))], nil))
177- let $t066606999 = if (choice)
173+ let $t066797018 = if (choice)
178174 then {
179175 let forNumber = gwxNumber
180176 let againstNumber = 0
187183 let choiceInteger = 0
188184 $Tuple3(forNumber, againstNumber, choiceInteger)
189185 }
190- let userPowerFor = $t066606999._1
191- let userPowerAgainst = $t066606999._2
192- let choiceInt = $t066606999._3
186+ let userPowerFor = $t066797018._1
187+ let userPowerAgainst = $t066797018._2
188+ let choiceInt = $t066797018._3
193189 let action = if ((userVoteInfoArray[1] == "1"))
194190 then StringEntry(keyProposalInfo(proposalIndex), formatProposalInfo(voteInfoArray[1], voteInfoArray[2], voteInfoArray[3], voteInfoArray[4], toString(((value(parseInt(voteInfoArray[5])) - value(parseInt(userVoteInfoArray[2]))) + userPowerFor)), toString((value(parseInt(voteInfoArray[6])) + userPowerAgainst))))
195191 else StringEntry(keyProposalInfo(proposalIndex), formatProposalInfo(voteInfoArray[1], voteInfoArray[2], voteInfoArray[3], voteInfoArray[4], toString((value(parseInt(voteInfoArray[5])) + userPowerFor)), toString(((value(parseInt(voteInfoArray[6])) - value(parseInt(userVoteInfoArray[2]))) + userPowerAgainst))))
219215 }
220216
221217
222-
223-@Callable(i)
224-func setManager (pendingManagerPublicKey) = {
225- let checkCaller = mustManager(i)
226- if ((checkCaller == checkCaller))
227- then {
228- let checkManagerPublicKey = fromBase58String(pendingManagerPublicKey)
229- if ((checkManagerPublicKey == checkManagerPublicKey))
230- then [StringEntry(keyPendingManagerPublicKey(), pendingManagerPublicKey)]
231- else throw("Strict value is not equal to itself.")
232- }
233- else throw("Strict value is not equal to itself.")
234- }
235-
236-
237-
238-@Callable(i)
239-func confirmManager () = {
240- let pm = pendingManagerPublicKeyOrUnit()
241- let hasPM = if (isDefined(pm))
242- then true
243- else throw("no pending manager")
244- if ((hasPM == hasPM))
245- then {
246- let checkPM = if ((i.callerPublicKey == value(pm)))
247- then true
248- else throw("you are not pending manager")
249- if ((checkPM == checkPM))
250- then [StringEntry(keyManagerPublicKey(), toBase58String(value(pm))), DeleteEntry(keyPendingManagerPublicKey())]
251- else throw("Strict value is not equal to itself.")
252- }
253- else throw("Strict value is not equal to itself.")
254- }
255-
256-
257218 @Verifier(tx)
258219 func verify () = {
259220 let targetPublicKey = match managerPublicKeyOrUnit() {
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 6 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let SEP = "__"
5-
6-func keyManagerPublicKey () = "%s__managerPublicpKey"
7-
8-
9-func keyPendingManagerPublicKey () = "%s__pendingManagerPublicKey"
10-
115
126 func blockHeightError () = throw("The block's height is too big for this proposal")
137
148
159 func alreadyVoteError () = throw("You have already voted")
1610
1711
1812 func noVoteError () = throw("You have not already voted")
1913
2014
2115 func gwxContractAddress () = makeString(["%s", "gwxContractAddress"], SEP)
2216
2317
2418 func keyCurrentIndex () = makeString(["%s", "currentIndex"], SEP)
2519
2620
2721 func keyProposalInfo (number) = makeString(["%s%d", "proposalInfo", toString(number)], SEP)
2822
2923
3024 func keyUserVoteOnProposal (number,user) = makeString(["%s%d%s", "userVoteOnProposal", toString(number), user], SEP)
3125
3226
27+func keyManagerPublicKey () = "%s__managerPublicKey"
28+
29+
30+func keyManagerVaultAddress () = "%s__managerVaultAddress"
31+
32+
3333 func getCurrentIndex () = getIntegerValue(this, keyCurrentIndex())
34+
35+
36+func getManagerAddressOrFail () = addressFromStringValue(getStringValue(keyManagerVaultAddress()))
3437
3538
3639 func formatProposalInfo (name,description,end,quorumNumber,positiveVotes,negativeVotes) = makeString(["%d%d%d%d%d%d", name, description, end, quorumNumber, positiveVotes, negativeVotes], SEP)
3740
3841
3942 func formatUserVoteOnProposal (vote,gwxNumber) = makeString(["%d%d", vote, gwxNumber], SEP)
4043
4144
4245 func asInt (val) = match val {
4346 case valInt: Int =>
4447 valInt
4548 case _ =>
4649 throw("fail to cast into Int")
4750 }
4851
4952
50-func managerPublicKeyOrUnit () = match getString(keyManagerPublicKey()) {
51- case s: String =>
52- fromBase58String(s)
53- case _: Unit =>
54- unit
55- case _ =>
56- throw("Match error")
57-}
58-
59-
60-func pendingManagerPublicKeyOrUnit () = match getString(keyPendingManagerPublicKey()) {
61- case s: String =>
62- fromBase58String(s)
63- case _: Unit =>
64- unit
65- case _ =>
66- throw("Match error")
67-}
53+func managerPublicKeyOrUnit () = {
54+ let managerVaultAddress = getManagerAddressOrFail()
55+ match getString(managerVaultAddress, keyManagerPublicKey()) {
56+ case s: String =>
57+ fromBase58String(s)
58+ case _: Unit =>
59+ unit
60+ case _ =>
61+ throw("Match error")
62+ }
63+ }
6864
6965
7066 func isManager (i) = match managerPublicKeyOrUnit() {
7167 case pk: ByteVector =>
7268 (i.callerPublicKey == pk)
7369 case _: Unit =>
7470 (i.caller == this)
7571 case _ =>
7672 throw("Match error")
7773 }
7874
7975
8076 func mustManager (i) = if (isManager(i))
8177 then true
8278 else throw("permission denied")
8379
8480
8581 @Callable(i)
8682 func startNewVote (name,description,expirationHeight,quorumNumber) = {
8783 let checks = [mustManager(i)]
8884 if ((checks == checks))
8985 then {
9086 let theIndex = getCurrentIndex()
9187 [IntegerEntry(keyCurrentIndex(), (theIndex + 1)), StringEntry(keyProposalInfo(theIndex), formatProposalInfo(name, description, toString((lastBlock.height + expirationHeight)), toString(quorumNumber), "0", "0"))]
9288 }
9389 else throw("Strict value is not equal to itself.")
9490 }
9591
9692
9793
9894 @Callable(i)
9995 func voteFor (proposalIndex,choice) = {
10096 let EMPTY = "EMPTY"
10197 let voteInfo = valueOrElse(getString(this, keyProposalInfo(proposalIndex)), EMPTY)
10298 let voteInfoArray = split(voteInfo, SEP)
10399 let userVoteInfo = valueOrElse(getString(this, keyUserVoteOnProposal(proposalIndex, toString(i.caller))), EMPTY)
104100 let checks = [if ((voteInfo != EMPTY))
105101 then true
106102 else throw("No such vote"), if ((value(parseInt(voteInfoArray[3])) > lastBlock.height))
107103 then true
108104 else blockHeightError(), if ((userVoteInfo == EMPTY))
109105 then true
110106 else alreadyVoteError()]
111107 if ((checks == checks))
112108 then {
113109 let gwxNumber = asInt(invoke(addressFromStringValue(getStringValue(gwxContractAddress())), "getUserGwxAmountAtHeightREADONLY", [toString(i.caller), value(parseInt(voteInfoArray[3]))], nil))
114- let $t033524440 = if (choice)
110+ let $t033714459 = if (choice)
115111 then {
116112 let action1 = StringEntry(keyProposalInfo(proposalIndex), formatProposalInfo(voteInfoArray[1], voteInfoArray[2], voteInfoArray[3], voteInfoArray[4], toString((value(parseInt(voteInfoArray[5])) + gwxNumber)), voteInfoArray[6]))
117113 let action2 = StringEntry(keyUserVoteOnProposal(proposalIndex, toString(i.caller)), formatUserVoteOnProposal("1", toString(gwxNumber)))
118114 $Tuple2(action1, action2)
119115 }
120116 else {
121117 let action1 = StringEntry(keyProposalInfo(proposalIndex), formatProposalInfo(voteInfoArray[1], voteInfoArray[2], voteInfoArray[3], voteInfoArray[4], voteInfoArray[5], toString((value(parseInt(voteInfoArray[6])) + gwxNumber))))
122118 let action2 = StringEntry(keyUserVoteOnProposal(proposalIndex, toString(i.caller)), formatUserVoteOnProposal("0", toString(gwxNumber)))
123119 $Tuple2(action1, action2)
124120 }
125- let action1 = $t033524440._1
126- let action2 = $t033524440._2
121+ let action1 = $t033714459._1
122+ let action2 = $t033714459._2
127123 [action1, action2]
128124 }
129125 else throw("Strict value is not equal to itself.")
130126 }
131127
132128
133129
134130 @Callable(i)
135131 func deleteVote (proposalIndex) = {
136132 let EMPTY = "EMPTY"
137133 let voteInfo = valueOrElse(getString(this, keyProposalInfo(proposalIndex)), EMPTY)
138134 let voteInfoArray = split(voteInfo, SEP)
139135 let userVoteInfo = valueOrElse(getString(this, keyUserVoteOnProposal(proposalIndex, toString(i.caller))), EMPTY)
140136 let userVoteInfoArray = split(userVoteInfo, SEP)
141137 let checks = [if ((voteInfo != EMPTY))
142138 then true
143139 else throw("No such vote"), if ((value(parseInt(voteInfoArray[3])) > lastBlock.height))
144140 then true
145141 else blockHeightError(), if ((userVoteInfo != EMPTY))
146142 then true
147143 else noVoteError()]
148144 if ((checks == checks))
149145 then {
150146 let action = if ((userVoteInfoArray[1] == "1"))
151147 then StringEntry(keyProposalInfo(proposalIndex), formatProposalInfo(voteInfoArray[1], voteInfoArray[2], voteInfoArray[3], voteInfoArray[4], toString((value(parseInt(voteInfoArray[5])) - value(parseInt(userVoteInfoArray[2])))), voteInfoArray[6]))
152148 else StringEntry(keyProposalInfo(proposalIndex), formatProposalInfo(voteInfoArray[1], voteInfoArray[2], voteInfoArray[3], voteInfoArray[4], voteInfoArray[5], toString((value(parseInt(voteInfoArray[6])) - value(parseInt(userVoteInfoArray[2]))))))
153149 [action, DeleteEntry(keyUserVoteOnProposal(proposalIndex, toString(i.caller)))]
154150 }
155151 else throw("Strict value is not equal to itself.")
156152 }
157153
158154
159155
160156 @Callable(i)
161157 func changeVote (proposalIndex,choice) = {
162158 let EMPTY = "EMPTY"
163159 let voteInfo = valueOrElse(getString(this, keyProposalInfo(proposalIndex)), EMPTY)
164160 let voteInfoArray = split(voteInfo, SEP)
165161 let userVoteInfo = valueOrElse(getString(this, keyUserVoteOnProposal(proposalIndex, toString(i.caller))), EMPTY)
166162 let userVoteInfoArray = split(userVoteInfo, SEP)
167163 let checks = [if ((voteInfo != EMPTY))
168164 then true
169165 else throw("No such vote"), if ((value(parseInt(voteInfoArray[3])) > lastBlock.height))
170166 then true
171167 else blockHeightError(), if ((userVoteInfo != EMPTY))
172168 then true
173169 else noVoteError()]
174170 if ((checks == checks))
175171 then {
176172 let gwxNumber = asInt(invoke(addressFromStringValue(getStringValue(gwxContractAddress())), "getUserGwxAmountAtHeightREADONLY", [toString(i.caller), value(parseInt(voteInfoArray[3]))], nil))
177- let $t066606999 = if (choice)
173+ let $t066797018 = if (choice)
178174 then {
179175 let forNumber = gwxNumber
180176 let againstNumber = 0
181177 let choiceInteger = 1
182178 $Tuple3(forNumber, againstNumber, choiceInteger)
183179 }
184180 else {
185181 let forNumber = 0
186182 let againstNumber = gwxNumber
187183 let choiceInteger = 0
188184 $Tuple3(forNumber, againstNumber, choiceInteger)
189185 }
190- let userPowerFor = $t066606999._1
191- let userPowerAgainst = $t066606999._2
192- let choiceInt = $t066606999._3
186+ let userPowerFor = $t066797018._1
187+ let userPowerAgainst = $t066797018._2
188+ let choiceInt = $t066797018._3
193189 let action = if ((userVoteInfoArray[1] == "1"))
194190 then StringEntry(keyProposalInfo(proposalIndex), formatProposalInfo(voteInfoArray[1], voteInfoArray[2], voteInfoArray[3], voteInfoArray[4], toString(((value(parseInt(voteInfoArray[5])) - value(parseInt(userVoteInfoArray[2]))) + userPowerFor)), toString((value(parseInt(voteInfoArray[6])) + userPowerAgainst))))
195191 else StringEntry(keyProposalInfo(proposalIndex), formatProposalInfo(voteInfoArray[1], voteInfoArray[2], voteInfoArray[3], voteInfoArray[4], toString((value(parseInt(voteInfoArray[5])) + userPowerFor)), toString(((value(parseInt(voteInfoArray[6])) - value(parseInt(userVoteInfoArray[2]))) + userPowerAgainst))))
196192 [action, StringEntry(keyUserVoteOnProposal(proposalIndex, toString(i.caller)), formatUserVoteOnProposal(toString(choiceInt), toString(gwxNumber)))]
197193 }
198194 else throw("Strict value is not equal to itself.")
199195 }
200196
201197
202198
203199 @Callable(i)
204200 func getResultREADONLY (proposalIndex) = {
205201 let EMPTY = "EMPTY"
206202 let voteInfo = valueOrElse(getString(this, keyProposalInfo(proposalIndex)), EMPTY)
207203 let voteInfoArray = split(voteInfo, SEP)
208204 let checks = [if ((voteInfo != EMPTY))
209205 then true
210206 else throw("No such vote")]
211207 if ((checks == checks))
212208 then {
213209 let positiveVotes = voteInfoArray[5]
214210 let negativeVotes = voteInfoArray[6]
215211 let quorumNumber = voteInfoArray[4]
216212 $Tuple2(nil, [positiveVotes, negativeVotes, quorumNumber])
217213 }
218214 else throw("Strict value is not equal to itself.")
219215 }
220216
221217
222-
223-@Callable(i)
224-func setManager (pendingManagerPublicKey) = {
225- let checkCaller = mustManager(i)
226- if ((checkCaller == checkCaller))
227- then {
228- let checkManagerPublicKey = fromBase58String(pendingManagerPublicKey)
229- if ((checkManagerPublicKey == checkManagerPublicKey))
230- then [StringEntry(keyPendingManagerPublicKey(), pendingManagerPublicKey)]
231- else throw("Strict value is not equal to itself.")
232- }
233- else throw("Strict value is not equal to itself.")
234- }
235-
236-
237-
238-@Callable(i)
239-func confirmManager () = {
240- let pm = pendingManagerPublicKeyOrUnit()
241- let hasPM = if (isDefined(pm))
242- then true
243- else throw("no pending manager")
244- if ((hasPM == hasPM))
245- then {
246- let checkPM = if ((i.callerPublicKey == value(pm)))
247- then true
248- else throw("you are not pending manager")
249- if ((checkPM == checkPM))
250- then [StringEntry(keyManagerPublicKey(), toBase58String(value(pm))), DeleteEntry(keyPendingManagerPublicKey())]
251- else throw("Strict value is not equal to itself.")
252- }
253- else throw("Strict value is not equal to itself.")
254- }
255-
256-
257218 @Verifier(tx)
258219 func verify () = {
259220 let targetPublicKey = match managerPublicKeyOrUnit() {
260221 case pk: ByteVector =>
261222 pk
262223 case _: Unit =>
263224 tx.senderPublicKey
264225 case _ =>
265226 throw("Match error")
266227 }
267228 sigVerify(tx.bodyBytes, tx.proofs[0], targetPublicKey)
268229 }
269230

github/deemru/w8io/169f3d6 
45.45 ms