tx · 2QF3YFjKo3NFapttqniLW3RFvHWQ5bNs2co4kzeT9cEk 3N4ziXSMRverXyxHDUKKMR9MHXnB3TyU3Yh: -0.01000000 Waves 2023.04.19 11:30 [2541204] smart account 3N4ziXSMRverXyxHDUKKMR9MHXnB3TyU3Yh > SELF 0.00000000 Waves
{ "type": 13, "id": "2QF3YFjKo3NFapttqniLW3RFvHWQ5bNs2co4kzeT9cEk", "fee": 1000000, "feeAssetId": null, "timestamp": 1681893088824, "version": 2, "chainId": 84, "sender": "3N4ziXSMRverXyxHDUKKMR9MHXnB3TyU3Yh", "senderPublicKey": "EU9obW1yVhR8qug3EmXPeew3DMagvJFQzY5Ku8bmcsU7", "proofs": [ "2ZCJqnUgunXNtrjFUfAudRxCnLMuywrpMqm4wD4KeM1tHxzYu3naDa2MCmsHvJDDmSoesZb5d3hxvSVfE4BcYQQ8" ], "script": "base64:BgIcCAISABIDCgEIEgASABIDCgEIEgMKAQgSAwoBCBkAA1NFUAICX18AEGNvbnRyYWN0RmlsZW5hbWUCEm1hbmFnZXJfdmF1bHQucmlkZQEIdGhyb3dFcnIBAXMJAAIBCQCsAgIJAKwCAgUQY29udHJhY3RGaWxlbmFtZQICOiAFAXMBGWtleUFjdGl2ZU1hbmFnZXJQdWJsaWNLZXkACQC5CQIJAMwIAgICJXMJAMwIAgIQbWFuYWdlclB1YmxpY0tleQUDbmlsBQNTRVABGmtleVBlbmRpbmdNYW5hZ2VyUHVibGljS2V5AAkAuQkCCQDMCAICAiVzCQDMCAICF3BlbmRpbmdNYW5hZ2VyUHVibGljS2V5BQNuaWwFA1NFUAEaa2V5Q3VycmVudE1hbmFnZXJQdWJsaWNLZXkACQC5CQIJAMwIAgICJXMJAMwIAgIXY3VycmVudE1hbmFnZXJQdWJsaWNLZXkFA25pbAUDU0VQARprZXlTZXROZXdNYW5hZ2VyVm90ZVByZWZpeAEQbWFuYWdlclB1YmxpY0tleQkAuQkCCQDMCAICBiVzJXMlcwkAzAgCAgpzZXRNYW5h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mtleVBlbmRpbmdNYW5hZ2VyUHVibGljS2V5AAQGcmVzdWx0CQDMCAIJAQtTdHJpbmdFbnRyeQIJAQ5rZXlBbGxvd2VkVHhJZAAFBHR4SWQFA25pbAkBDHZvdGVJTlRFUk5BTAQFE2NhbGxlckFkZHJlc3NTdHJpbmcFCWtleVByZWZpeAUIbWluVm90ZXMFBnJlc3VsdABwsB0K", "height": 2541204, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: EV5YW1beov4z2RbLv43sHGzkXaLY4NP94ukUEubTz7Np Next: HwWXuo7m8vuqmiFCKSmqiYCbHmN7ffcSPeqHqSaGA7GA Diff:
Old | New | Differences | |
---|---|---|---|
20 | 20 | func h (i) = makeString(["%s%s%s", "setManager", i], a) | |
21 | 21 | ||
22 | 22 | ||
23 | - | func j ( | |
23 | + | func j () = makeString(["%s%s", "deactivateManager"], a) | |
24 | 24 | ||
25 | 25 | ||
26 | - | func | |
26 | + | func k () = makeString(["%s%s", "activateManager"], a) | |
27 | 27 | ||
28 | 28 | ||
29 | - | func | |
29 | + | func l (m) = makeString(["%s%s%s", "addAdmin", m], a) | |
30 | 30 | ||
31 | 31 | ||
32 | - | func n ( | |
32 | + | func n (o) = makeString(["%s%s%s", "removeAdmin", o], a) | |
33 | 33 | ||
34 | 34 | ||
35 | - | func | |
35 | + | func p (q) = makeString(["%s%s%s", "allowTxId", q], a) | |
36 | 36 | ||
37 | 37 | ||
38 | - | func | |
38 | + | func r () = makeString(["%s", "adminAddressList"], a) | |
39 | 39 | ||
40 | 40 | ||
41 | - | func | |
41 | + | func s () = makeString(["%s", "TXID"], a) | |
42 | 42 | ||
43 | 43 | ||
44 | - | func r (k) = valueOrElse(getInteger(q(k)), 0) | |
44 | + | func t (u,v) = { | |
45 | + | let w = makeString([u, v], a) | |
46 | + | valueOrElse(getInteger(w), 0) | |
47 | + | } | |
45 | 48 | ||
46 | 49 | ||
47 | - | func s (t) = makeString(["%s%s%s", "addAdmin", t], a) | |
48 | - | ||
49 | - | ||
50 | - | func u (t,k) = makeString([s(t), k], a) | |
51 | - | ||
52 | - | ||
53 | - | func v (t,k) = valueOrElse(getInteger(u(t, k)), 0) | |
54 | - | ||
55 | - | ||
56 | - | func w (x) = makeString(["%s%s%s", "removeAdmin", x], a) | |
57 | - | ||
58 | - | ||
59 | - | func y (x,k) = makeString([w(x), k], a) | |
60 | - | ||
61 | - | ||
62 | - | func z (x,k) = valueOrElse(getInteger(y(x, k)), 0) | |
63 | - | ||
64 | - | ||
65 | - | func A () = makeString(["%s%s", "activateManager"], a) | |
66 | - | ||
67 | - | ||
68 | - | func B (k) = makeString([A(), k], a) | |
69 | - | ||
70 | - | ||
71 | - | func C (k) = valueOrElse(getInteger(B(k)), 0) | |
72 | - | ||
73 | - | ||
74 | - | func D () = makeString(["%s", "adminAddressList"], a) | |
75 | - | ||
76 | - | ||
77 | - | func E () = { | |
78 | - | let F = getString(f()) | |
79 | - | if ($isInstanceOf(F, "String")) | |
50 | + | func x () = { | |
51 | + | let y = getString(f()) | |
52 | + | if ($isInstanceOf(y, "String")) | |
80 | 53 | then { | |
81 | - | let d = | |
54 | + | let d = y | |
82 | 55 | fromBase58String(d) | |
83 | 56 | } | |
84 | - | else if ($isInstanceOf( | |
57 | + | else if ($isInstanceOf(y, "Unit")) | |
85 | 58 | then unit | |
86 | 59 | else throw("Match error") | |
87 | 60 | } | |
88 | 61 | ||
89 | 62 | ||
90 | - | func | |
63 | + | func z () = split(valueOrElse(getString(this, r()), ""), a) | |
91 | 64 | ||
92 | 65 | ||
93 | - | func | |
94 | - | let | |
95 | - | if ($isInstanceOf( | |
66 | + | func A (B) = { | |
67 | + | let y = indexOf(z(), B) | |
68 | + | if ($isInstanceOf(y, "Int")) | |
96 | 69 | then { | |
97 | - | let | |
70 | + | let C = y | |
98 | 71 | true | |
99 | 72 | } | |
100 | 73 | else false | |
101 | 74 | } | |
102 | 75 | ||
103 | 76 | ||
104 | - | func | |
105 | - | let | |
106 | - | let | |
107 | - | let | |
108 | - | $Tuple2(( | |
77 | + | func D (E,F) = { | |
78 | + | let G = E | |
79 | + | let H = G._1 | |
80 | + | let u = G._2 | |
81 | + | $Tuple2((H :+ makeString([u, F], a)), u) | |
109 | 82 | } | |
110 | 83 | ||
111 | 84 | ||
112 | - | func | |
113 | - | let | |
114 | - | let | |
115 | - | let | |
116 | - | let | |
117 | - | func | |
118 | - | then | |
119 | - | else | |
85 | + | func I (J) = { | |
86 | + | let K = r() | |
87 | + | let L = z() | |
88 | + | let M = size(L) | |
89 | + | let N = $Tuple2(nil, J) | |
90 | + | func O (P,Q) = if ((Q >= M)) | |
91 | + | then P | |
92 | + | else D(P, L[Q]) | |
120 | 93 | ||
121 | - | func | |
122 | - | then | |
94 | + | func R (P,Q) = if ((Q >= M)) | |
95 | + | then P | |
123 | 96 | else throw("List size exceeds 10") | |
124 | 97 | ||
125 | - | | |
98 | + | R(O(O(O(O(O(O(O(O(O(O(N, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10) | |
126 | 99 | } | |
127 | 100 | ||
128 | 101 | ||
129 | - | func | |
102 | + | func S (H,w) = (H + valueOrElse(getInteger(w), 0)) | |
130 | 103 | ||
131 | 104 | ||
132 | - | func | |
133 | - | let | |
134 | - | let | |
135 | - | let | |
136 | - | let | |
137 | - | func | |
138 | - | then | |
139 | - | else | |
105 | + | func T (u) = { | |
106 | + | let U = I(u)._1 | |
107 | + | let L = U | |
108 | + | let M = size(L) | |
109 | + | let N = 0 | |
110 | + | func O (P,Q) = if ((Q >= M)) | |
111 | + | then P | |
112 | + | else S(P, L[Q]) | |
140 | 113 | ||
141 | - | func | |
142 | - | then | |
114 | + | func R (P,Q) = if ((Q >= M)) | |
115 | + | then P | |
143 | 116 | else throw("List size exceeds 10") | |
144 | 117 | ||
145 | - | | |
118 | + | R(O(O(O(O(O(O(O(O(O(O(N, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10) | |
146 | 119 | } | |
147 | 120 | ||
148 | 121 | ||
149 | - | func | |
122 | + | func V (H,W) = (H :+ DeleteEntry(W)) | |
150 | 123 | ||
151 | 124 | ||
152 | - | func | |
153 | - | let | |
154 | - | let | |
155 | - | let | |
156 | - | let | |
157 | - | func | |
158 | - | then | |
159 | - | else | |
125 | + | func X (u) = { | |
126 | + | let U = I(u)._1 | |
127 | + | let L = U | |
128 | + | let M = size(L) | |
129 | + | let N = nil | |
130 | + | func O (P,Q) = if ((Q >= M)) | |
131 | + | then P | |
132 | + | else V(P, L[Q]) | |
160 | 133 | ||
161 | - | func | |
162 | - | then | |
134 | + | func R (P,Q) = if ((Q >= M)) | |
135 | + | then P | |
163 | 136 | else throw("List size exceeds 10") | |
164 | 137 | ||
165 | - | | |
138 | + | R(O(O(O(O(O(O(O(O(O(O(N, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10) | |
166 | 139 | } | |
167 | 140 | ||
168 | 141 | ||
169 | - | func ah (ai,aj,R,ak,al) = { | |
170 | - | let ab = makeString([R, ai], a) | |
171 | - | if (H(ai)) | |
172 | - | then if ((aj == 1)) | |
173 | - | then c((ab + " you already voted")) | |
142 | + | func Y (Z,J,aa,ab) = { | |
143 | + | let w = makeString([J, Z], a) | |
144 | + | let ac = t(J, Z) | |
145 | + | if (A(Z)) | |
146 | + | then if ((ac == 1)) | |
147 | + | then c((w + " you already voted")) | |
174 | 148 | else { | |
175 | - | let | |
176 | - | if ((( | |
149 | + | let U = T(J) | |
150 | + | if (((U + 1) >= aa)) | |
177 | 151 | then { | |
178 | - | let | |
179 | - | ( | |
152 | + | let ad = X(J) | |
153 | + | (ad ++ ab) | |
180 | 154 | } | |
181 | - | else [IntegerEntry( | |
155 | + | else [IntegerEntry(w, 1)] | |
182 | 156 | } | |
183 | - | else c((("Address: " + | |
157 | + | else c((("Address: " + Z) + " not in Admin list")) | |
184 | 158 | } | |
185 | 159 | ||
186 | 160 | ||
187 | - | @Callable( | |
161 | + | @Callable(ae) | |
188 | 162 | func confirmManager () = { | |
189 | - | let | |
190 | - | let | |
163 | + | let af = x() | |
164 | + | let ag = if (isDefined(af)) | |
191 | 165 | then true | |
192 | 166 | else c("no pending manager") | |
193 | - | if (( | |
167 | + | if ((ag == ag)) | |
194 | 168 | then { | |
195 | - | let | |
169 | + | let ah = if ((ae.callerPublicKey == value(af))) | |
196 | 170 | then true | |
197 | 171 | else c("you are not pending manager") | |
198 | - | if (( | |
199 | - | then [StringEntry(g(), toBase58String(value( | |
172 | + | if ((ah == ah)) | |
173 | + | then [StringEntry(g(), toBase58String(value(af)))] | |
200 | 174 | else throw("Strict value is not equal to itself.") | |
201 | 175 | } | |
202 | 176 | else throw("Strict value is not equal to itself.") | |
204 | 178 | ||
205 | 179 | ||
206 | 180 | ||
207 | - | @Callable(an) | |
208 | - | func voteForNewManger (ar) = { | |
209 | - | let ai = toBase58String(an.caller.bytes) | |
210 | - | let R = h(ar) | |
211 | - | let aj = l(ar, ai) | |
212 | - | let ak = 2 | |
213 | - | let O = [StringEntry(f(), ar)] | |
214 | - | ah(ai, aj, R, ak, O) | |
181 | + | @Callable(ae) | |
182 | + | func voteForNewManger (ai) = { | |
183 | + | let Z = toBase58String(ae.caller.bytes) | |
184 | + | let J = h(ai) | |
185 | + | let aa = 2 | |
186 | + | let H = [StringEntry(f(), ai)] | |
187 | + | Y(Z, J, aa, H) | |
215 | 188 | } | |
216 | 189 | ||
217 | 190 | ||
218 | 191 | ||
219 | - | @Callable( | |
192 | + | @Callable(ae) | |
220 | 193 | func deactivateManager () = { | |
221 | - | let ai = toBase58String(an.caller.bytes) | |
222 | - | let R = m() | |
223 | - | let aj = o(ai) | |
224 | - | let ak = 1 | |
225 | - | let O = [StringEntry(e(), "disabled")] | |
226 | - | ah(ai, aj, R, ak, O) | |
194 | + | let Z = toBase58String(ae.caller.bytes) | |
195 | + | let J = j() | |
196 | + | let aa = 1 | |
197 | + | let H = [StringEntry(e(), "disabled")] | |
198 | + | Y(Z, J, aa, H) | |
227 | 199 | } | |
228 | 200 | ||
229 | 201 | ||
230 | 202 | ||
231 | - | @Callable( | |
203 | + | @Callable(ae) | |
232 | 204 | func activateManager () = { | |
233 | - | let ai = toBase58String(an.caller.bytes) | |
234 | - | let R = p() | |
235 | - | let aj = r(ai) | |
236 | - | let ak = 2 | |
237 | - | let as = getStringValue(g()) | |
238 | - | let O = [StringEntry(e(), as)] | |
239 | - | ah(ai, aj, R, ak, O) | |
205 | + | let Z = toBase58String(ae.caller.bytes) | |
206 | + | let J = k() | |
207 | + | let aa = 2 | |
208 | + | let aj = getStringValue(g()) | |
209 | + | let H = [StringEntry(e(), aj)] | |
210 | + | Y(Z, J, aa, H) | |
240 | 211 | } | |
241 | 212 | ||
242 | 213 | ||
243 | 214 | ||
244 | - | @Callable(an) | |
245 | - | func addNewAdmin (at) = { | |
246 | - | let ai = toBase58String(an.caller.bytes) | |
247 | - | let R = s(at) | |
248 | - | let aj = v(at, ai) | |
249 | - | let ak = 2 | |
250 | - | let au = G() | |
251 | - | let F = indexOf(au, at) | |
252 | - | if ($isInstanceOf(F, "Int")) | |
215 | + | @Callable(ae) | |
216 | + | func addNewAdmin (ak) = { | |
217 | + | let Z = toBase58String(ae.caller.bytes) | |
218 | + | let J = l(ak) | |
219 | + | let aa = 2 | |
220 | + | let al = z() | |
221 | + | let y = indexOf(al, ak) | |
222 | + | if ($isInstanceOf(y, "Int")) | |
253 | 223 | then { | |
254 | - | let | |
255 | - | c(( | |
224 | + | let E = y | |
225 | + | c((ak + " already in Admin List")) | |
256 | 226 | } | |
257 | 227 | else { | |
258 | - | let | |
259 | - | let | |
260 | - | | |
228 | + | let am = (al :+ ak) | |
229 | + | let H = [StringEntry(r(), makeString(am, a))] | |
230 | + | Y(Z, J, aa, H) | |
261 | 231 | } | |
262 | 232 | } | |
263 | 233 | ||
264 | 234 | ||
265 | 235 | ||
266 | - | @Callable(an) | |
267 | - | func removeAdmin (x) = { | |
268 | - | let ai = toBase58String(an.caller.bytes) | |
269 | - | let R = w(x) | |
270 | - | let aj = z(x, ai) | |
271 | - | let ak = 2 | |
272 | - | let au = G() | |
273 | - | let F = indexOf(au, x) | |
274 | - | if ($isInstanceOf(F, "Int")) | |
236 | + | @Callable(ae) | |
237 | + | func removeAdmin (o) = { | |
238 | + | let Z = toBase58String(ae.caller.bytes) | |
239 | + | let J = n(o) | |
240 | + | let aa = 2 | |
241 | + | let al = z() | |
242 | + | let y = indexOf(al, o) | |
243 | + | if ($isInstanceOf(y, "Int")) | |
275 | 244 | then { | |
276 | - | let | |
277 | - | let | |
278 | - | let | |
279 | - | | |
245 | + | let an = y | |
246 | + | let am = removeByIndex(al, an) | |
247 | + | let H = [StringEntry(r(), makeString(am, a))] | |
248 | + | Y(Z, J, aa, H) | |
280 | 249 | } | |
281 | - | else c(( | |
250 | + | else c((o + " not found in Admin List")) | |
282 | 251 | } | |
283 | 252 | ||
284 | 253 | ||
285 | 254 | ||
286 | - | @Callable(an) | |
287 | - | func unlockVarifier () = { | |
288 | - | let ai = toBase58String(an.caller.bytes) | |
289 | - | let R = p() | |
290 | - | let aj = r(ai) | |
291 | - | let ak = 2 | |
292 | - | let ax = getStringValue(f()) | |
293 | - | let O = [StringEntry(e(), ax)] | |
294 | - | ah(ai, aj, R, ak, O) | |
255 | + | @Callable(ae) | |
256 | + | func voteForTxId (q) = { | |
257 | + | let Z = toBase58String(ae.caller.bytes) | |
258 | + | let J = p(q) | |
259 | + | let aa = 2 | |
260 | + | let ao = getStringValue(f()) | |
261 | + | let H = [StringEntry(s(), q)] | |
262 | + | Y(Z, J, aa, H) | |
295 | 263 | } | |
296 | 264 | ||
297 | 265 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = "__" | |
5 | 5 | ||
6 | 6 | let b = "manager_vault.ride" | |
7 | 7 | ||
8 | 8 | func c (d) = throw(((b + ": ") + d)) | |
9 | 9 | ||
10 | 10 | ||
11 | 11 | func e () = makeString(["%s", "managerPublicKey"], a) | |
12 | 12 | ||
13 | 13 | ||
14 | 14 | func f () = makeString(["%s", "pendingManagerPublicKey"], a) | |
15 | 15 | ||
16 | 16 | ||
17 | 17 | func g () = makeString(["%s", "currentManagerPublicKey"], a) | |
18 | 18 | ||
19 | 19 | ||
20 | 20 | func h (i) = makeString(["%s%s%s", "setManager", i], a) | |
21 | 21 | ||
22 | 22 | ||
23 | - | func j ( | |
23 | + | func j () = makeString(["%s%s", "deactivateManager"], a) | |
24 | 24 | ||
25 | 25 | ||
26 | - | func | |
26 | + | func k () = makeString(["%s%s", "activateManager"], a) | |
27 | 27 | ||
28 | 28 | ||
29 | - | func | |
29 | + | func l (m) = makeString(["%s%s%s", "addAdmin", m], a) | |
30 | 30 | ||
31 | 31 | ||
32 | - | func n ( | |
32 | + | func n (o) = makeString(["%s%s%s", "removeAdmin", o], a) | |
33 | 33 | ||
34 | 34 | ||
35 | - | func | |
35 | + | func p (q) = makeString(["%s%s%s", "allowTxId", q], a) | |
36 | 36 | ||
37 | 37 | ||
38 | - | func | |
38 | + | func r () = makeString(["%s", "adminAddressList"], a) | |
39 | 39 | ||
40 | 40 | ||
41 | - | func | |
41 | + | func s () = makeString(["%s", "TXID"], a) | |
42 | 42 | ||
43 | 43 | ||
44 | - | func r (k) = valueOrElse(getInteger(q(k)), 0) | |
44 | + | func t (u,v) = { | |
45 | + | let w = makeString([u, v], a) | |
46 | + | valueOrElse(getInteger(w), 0) | |
47 | + | } | |
45 | 48 | ||
46 | 49 | ||
47 | - | func s (t) = makeString(["%s%s%s", "addAdmin", t], a) | |
48 | - | ||
49 | - | ||
50 | - | func u (t,k) = makeString([s(t), k], a) | |
51 | - | ||
52 | - | ||
53 | - | func v (t,k) = valueOrElse(getInteger(u(t, k)), 0) | |
54 | - | ||
55 | - | ||
56 | - | func w (x) = makeString(["%s%s%s", "removeAdmin", x], a) | |
57 | - | ||
58 | - | ||
59 | - | func y (x,k) = makeString([w(x), k], a) | |
60 | - | ||
61 | - | ||
62 | - | func z (x,k) = valueOrElse(getInteger(y(x, k)), 0) | |
63 | - | ||
64 | - | ||
65 | - | func A () = makeString(["%s%s", "activateManager"], a) | |
66 | - | ||
67 | - | ||
68 | - | func B (k) = makeString([A(), k], a) | |
69 | - | ||
70 | - | ||
71 | - | func C (k) = valueOrElse(getInteger(B(k)), 0) | |
72 | - | ||
73 | - | ||
74 | - | func D () = makeString(["%s", "adminAddressList"], a) | |
75 | - | ||
76 | - | ||
77 | - | func E () = { | |
78 | - | let F = getString(f()) | |
79 | - | if ($isInstanceOf(F, "String")) | |
50 | + | func x () = { | |
51 | + | let y = getString(f()) | |
52 | + | if ($isInstanceOf(y, "String")) | |
80 | 53 | then { | |
81 | - | let d = | |
54 | + | let d = y | |
82 | 55 | fromBase58String(d) | |
83 | 56 | } | |
84 | - | else if ($isInstanceOf( | |
57 | + | else if ($isInstanceOf(y, "Unit")) | |
85 | 58 | then unit | |
86 | 59 | else throw("Match error") | |
87 | 60 | } | |
88 | 61 | ||
89 | 62 | ||
90 | - | func | |
63 | + | func z () = split(valueOrElse(getString(this, r()), ""), a) | |
91 | 64 | ||
92 | 65 | ||
93 | - | func | |
94 | - | let | |
95 | - | if ($isInstanceOf( | |
66 | + | func A (B) = { | |
67 | + | let y = indexOf(z(), B) | |
68 | + | if ($isInstanceOf(y, "Int")) | |
96 | 69 | then { | |
97 | - | let | |
70 | + | let C = y | |
98 | 71 | true | |
99 | 72 | } | |
100 | 73 | else false | |
101 | 74 | } | |
102 | 75 | ||
103 | 76 | ||
104 | - | func | |
105 | - | let | |
106 | - | let | |
107 | - | let | |
108 | - | $Tuple2(( | |
77 | + | func D (E,F) = { | |
78 | + | let G = E | |
79 | + | let H = G._1 | |
80 | + | let u = G._2 | |
81 | + | $Tuple2((H :+ makeString([u, F], a)), u) | |
109 | 82 | } | |
110 | 83 | ||
111 | 84 | ||
112 | - | func | |
113 | - | let | |
114 | - | let | |
115 | - | let | |
116 | - | let | |
117 | - | func | |
118 | - | then | |
119 | - | else | |
85 | + | func I (J) = { | |
86 | + | let K = r() | |
87 | + | let L = z() | |
88 | + | let M = size(L) | |
89 | + | let N = $Tuple2(nil, J) | |
90 | + | func O (P,Q) = if ((Q >= M)) | |
91 | + | then P | |
92 | + | else D(P, L[Q]) | |
120 | 93 | ||
121 | - | func | |
122 | - | then | |
94 | + | func R (P,Q) = if ((Q >= M)) | |
95 | + | then P | |
123 | 96 | else throw("List size exceeds 10") | |
124 | 97 | ||
125 | - | | |
98 | + | R(O(O(O(O(O(O(O(O(O(O(N, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10) | |
126 | 99 | } | |
127 | 100 | ||
128 | 101 | ||
129 | - | func | |
102 | + | func S (H,w) = (H + valueOrElse(getInteger(w), 0)) | |
130 | 103 | ||
131 | 104 | ||
132 | - | func | |
133 | - | let | |
134 | - | let | |
135 | - | let | |
136 | - | let | |
137 | - | func | |
138 | - | then | |
139 | - | else | |
105 | + | func T (u) = { | |
106 | + | let U = I(u)._1 | |
107 | + | let L = U | |
108 | + | let M = size(L) | |
109 | + | let N = 0 | |
110 | + | func O (P,Q) = if ((Q >= M)) | |
111 | + | then P | |
112 | + | else S(P, L[Q]) | |
140 | 113 | ||
141 | - | func | |
142 | - | then | |
114 | + | func R (P,Q) = if ((Q >= M)) | |
115 | + | then P | |
143 | 116 | else throw("List size exceeds 10") | |
144 | 117 | ||
145 | - | | |
118 | + | R(O(O(O(O(O(O(O(O(O(O(N, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10) | |
146 | 119 | } | |
147 | 120 | ||
148 | 121 | ||
149 | - | func | |
122 | + | func V (H,W) = (H :+ DeleteEntry(W)) | |
150 | 123 | ||
151 | 124 | ||
152 | - | func | |
153 | - | let | |
154 | - | let | |
155 | - | let | |
156 | - | let | |
157 | - | func | |
158 | - | then | |
159 | - | else | |
125 | + | func X (u) = { | |
126 | + | let U = I(u)._1 | |
127 | + | let L = U | |
128 | + | let M = size(L) | |
129 | + | let N = nil | |
130 | + | func O (P,Q) = if ((Q >= M)) | |
131 | + | then P | |
132 | + | else V(P, L[Q]) | |
160 | 133 | ||
161 | - | func | |
162 | - | then | |
134 | + | func R (P,Q) = if ((Q >= M)) | |
135 | + | then P | |
163 | 136 | else throw("List size exceeds 10") | |
164 | 137 | ||
165 | - | | |
138 | + | R(O(O(O(O(O(O(O(O(O(O(N, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10) | |
166 | 139 | } | |
167 | 140 | ||
168 | 141 | ||
169 | - | func ah (ai,aj,R,ak,al) = { | |
170 | - | let ab = makeString([R, ai], a) | |
171 | - | if (H(ai)) | |
172 | - | then if ((aj == 1)) | |
173 | - | then c((ab + " you already voted")) | |
142 | + | func Y (Z,J,aa,ab) = { | |
143 | + | let w = makeString([J, Z], a) | |
144 | + | let ac = t(J, Z) | |
145 | + | if (A(Z)) | |
146 | + | then if ((ac == 1)) | |
147 | + | then c((w + " you already voted")) | |
174 | 148 | else { | |
175 | - | let | |
176 | - | if ((( | |
149 | + | let U = T(J) | |
150 | + | if (((U + 1) >= aa)) | |
177 | 151 | then { | |
178 | - | let | |
179 | - | ( | |
152 | + | let ad = X(J) | |
153 | + | (ad ++ ab) | |
180 | 154 | } | |
181 | - | else [IntegerEntry( | |
155 | + | else [IntegerEntry(w, 1)] | |
182 | 156 | } | |
183 | - | else c((("Address: " + | |
157 | + | else c((("Address: " + Z) + " not in Admin list")) | |
184 | 158 | } | |
185 | 159 | ||
186 | 160 | ||
187 | - | @Callable( | |
161 | + | @Callable(ae) | |
188 | 162 | func confirmManager () = { | |
189 | - | let | |
190 | - | let | |
163 | + | let af = x() | |
164 | + | let ag = if (isDefined(af)) | |
191 | 165 | then true | |
192 | 166 | else c("no pending manager") | |
193 | - | if (( | |
167 | + | if ((ag == ag)) | |
194 | 168 | then { | |
195 | - | let | |
169 | + | let ah = if ((ae.callerPublicKey == value(af))) | |
196 | 170 | then true | |
197 | 171 | else c("you are not pending manager") | |
198 | - | if (( | |
199 | - | then [StringEntry(g(), toBase58String(value( | |
172 | + | if ((ah == ah)) | |
173 | + | then [StringEntry(g(), toBase58String(value(af)))] | |
200 | 174 | else throw("Strict value is not equal to itself.") | |
201 | 175 | } | |
202 | 176 | else throw("Strict value is not equal to itself.") | |
203 | 177 | } | |
204 | 178 | ||
205 | 179 | ||
206 | 180 | ||
207 | - | @Callable(an) | |
208 | - | func voteForNewManger (ar) = { | |
209 | - | let ai = toBase58String(an.caller.bytes) | |
210 | - | let R = h(ar) | |
211 | - | let aj = l(ar, ai) | |
212 | - | let ak = 2 | |
213 | - | let O = [StringEntry(f(), ar)] | |
214 | - | ah(ai, aj, R, ak, O) | |
181 | + | @Callable(ae) | |
182 | + | func voteForNewManger (ai) = { | |
183 | + | let Z = toBase58String(ae.caller.bytes) | |
184 | + | let J = h(ai) | |
185 | + | let aa = 2 | |
186 | + | let H = [StringEntry(f(), ai)] | |
187 | + | Y(Z, J, aa, H) | |
215 | 188 | } | |
216 | 189 | ||
217 | 190 | ||
218 | 191 | ||
219 | - | @Callable( | |
192 | + | @Callable(ae) | |
220 | 193 | func deactivateManager () = { | |
221 | - | let ai = toBase58String(an.caller.bytes) | |
222 | - | let R = m() | |
223 | - | let aj = o(ai) | |
224 | - | let ak = 1 | |
225 | - | let O = [StringEntry(e(), "disabled")] | |
226 | - | ah(ai, aj, R, ak, O) | |
194 | + | let Z = toBase58String(ae.caller.bytes) | |
195 | + | let J = j() | |
196 | + | let aa = 1 | |
197 | + | let H = [StringEntry(e(), "disabled")] | |
198 | + | Y(Z, J, aa, H) | |
227 | 199 | } | |
228 | 200 | ||
229 | 201 | ||
230 | 202 | ||
231 | - | @Callable( | |
203 | + | @Callable(ae) | |
232 | 204 | func activateManager () = { | |
233 | - | let ai = toBase58String(an.caller.bytes) | |
234 | - | let R = p() | |
235 | - | let aj = r(ai) | |
236 | - | let ak = 2 | |
237 | - | let as = getStringValue(g()) | |
238 | - | let O = [StringEntry(e(), as)] | |
239 | - | ah(ai, aj, R, ak, O) | |
205 | + | let Z = toBase58String(ae.caller.bytes) | |
206 | + | let J = k() | |
207 | + | let aa = 2 | |
208 | + | let aj = getStringValue(g()) | |
209 | + | let H = [StringEntry(e(), aj)] | |
210 | + | Y(Z, J, aa, H) | |
240 | 211 | } | |
241 | 212 | ||
242 | 213 | ||
243 | 214 | ||
244 | - | @Callable(an) | |
245 | - | func addNewAdmin (at) = { | |
246 | - | let ai = toBase58String(an.caller.bytes) | |
247 | - | let R = s(at) | |
248 | - | let aj = v(at, ai) | |
249 | - | let ak = 2 | |
250 | - | let au = G() | |
251 | - | let F = indexOf(au, at) | |
252 | - | if ($isInstanceOf(F, "Int")) | |
215 | + | @Callable(ae) | |
216 | + | func addNewAdmin (ak) = { | |
217 | + | let Z = toBase58String(ae.caller.bytes) | |
218 | + | let J = l(ak) | |
219 | + | let aa = 2 | |
220 | + | let al = z() | |
221 | + | let y = indexOf(al, ak) | |
222 | + | if ($isInstanceOf(y, "Int")) | |
253 | 223 | then { | |
254 | - | let | |
255 | - | c(( | |
224 | + | let E = y | |
225 | + | c((ak + " already in Admin List")) | |
256 | 226 | } | |
257 | 227 | else { | |
258 | - | let | |
259 | - | let | |
260 | - | | |
228 | + | let am = (al :+ ak) | |
229 | + | let H = [StringEntry(r(), makeString(am, a))] | |
230 | + | Y(Z, J, aa, H) | |
261 | 231 | } | |
262 | 232 | } | |
263 | 233 | ||
264 | 234 | ||
265 | 235 | ||
266 | - | @Callable(an) | |
267 | - | func removeAdmin (x) = { | |
268 | - | let ai = toBase58String(an.caller.bytes) | |
269 | - | let R = w(x) | |
270 | - | let aj = z(x, ai) | |
271 | - | let ak = 2 | |
272 | - | let au = G() | |
273 | - | let F = indexOf(au, x) | |
274 | - | if ($isInstanceOf(F, "Int")) | |
236 | + | @Callable(ae) | |
237 | + | func removeAdmin (o) = { | |
238 | + | let Z = toBase58String(ae.caller.bytes) | |
239 | + | let J = n(o) | |
240 | + | let aa = 2 | |
241 | + | let al = z() | |
242 | + | let y = indexOf(al, o) | |
243 | + | if ($isInstanceOf(y, "Int")) | |
275 | 244 | then { | |
276 | - | let | |
277 | - | let | |
278 | - | let | |
279 | - | | |
245 | + | let an = y | |
246 | + | let am = removeByIndex(al, an) | |
247 | + | let H = [StringEntry(r(), makeString(am, a))] | |
248 | + | Y(Z, J, aa, H) | |
280 | 249 | } | |
281 | - | else c(( | |
250 | + | else c((o + " not found in Admin List")) | |
282 | 251 | } | |
283 | 252 | ||
284 | 253 | ||
285 | 254 | ||
286 | - | @Callable(an) | |
287 | - | func unlockVarifier () = { | |
288 | - | let ai = toBase58String(an.caller.bytes) | |
289 | - | let R = p() | |
290 | - | let aj = r(ai) | |
291 | - | let ak = 2 | |
292 | - | let ax = getStringValue(f()) | |
293 | - | let O = [StringEntry(e(), ax)] | |
294 | - | ah(ai, aj, R, ak, O) | |
255 | + | @Callable(ae) | |
256 | + | func voteForTxId (q) = { | |
257 | + | let Z = toBase58String(ae.caller.bytes) | |
258 | + | let J = p(q) | |
259 | + | let aa = 2 | |
260 | + | let ao = getStringValue(f()) | |
261 | + | let H = [StringEntry(s(), q)] | |
262 | + | Y(Z, J, aa, H) | |
295 | 263 | } | |
296 | 264 | ||
297 | 265 |
github/deemru/w8io/026f985 64.66 ms ◑