tx · GcmnqKtf1iH9m1Jkj9ehTPWFgLg5cr17ff2Rewio4Jz4

3MrwiwvG6BeUNCyXBfSAHgaXHASsxbjYMVF:  -0.01000000 Waves

2022.10.11 16:54 [2267763] smart account 3MrwiwvG6BeUNCyXBfSAHgaXHASsxbjYMVF > SELF 0.00000000 Waves

{ "type": 13, "id": "GcmnqKtf1iH9m1Jkj9ehTPWFgLg5cr17ff2Rewio4Jz4", "fee": 1000000, "feeAssetId": null, "timestamp": 1665496517313, "version": 2, "chainId": 84, "sender": "3MrwiwvG6BeUNCyXBfSAHgaXHASsxbjYMVF", "senderPublicKey": "7m7j9TNbV4vKeeJqy37XpMNH784X3GGN6acbgLwbBiDD", "proofs": [ "56piCnp3HbZamzYwHAxVAhWrKgndwH5i1hF9gV3TyUYg2HVDiCVf1ecJiQNEEFrjG3Hh2aLpyppXeQU5bWS77h8g" ], "script": "base64:AAIFAAAAAAAAABcIAhIHCgUBCAgYGBIECgIBARIECgIBEQAAABwAAAAADWtBZG1pblB1YktleTECAAAAC2FkbWluX3B1Yl8xAAAAAA1rQWRtaW5QdWJLZXkyAgAAAAthZG1pbl9wdWJfMgAAAAANa0FkbWluUHViS2V5MwIAAAALYWRtaW5fcHViXzMAAAAAEmtBZG1pbkludm9rZVB1YktleQIAAAAQYWRtaW5faW52b2tlX3B1YgAAAAAQa01vbmV5Qm94QWRkcmVzcwIAAAARbW9uZXlfYm94X2FkZHJlc3MAAAAAC2tHb3ZBZGRyZXNzAgAAABJnb3Zlcm5hbmNlX2FkZHJlc3MAAAAAB2tBY3RpdmUCAAAABmFjdGl2ZQAAAAANa0xhc3RTdXJ2ZXlJZAIAAAAObGFzdF9zdXJ2ZXlfaWQAAAAAF2tTdXJ2ZXlIZWlnaHRDb21wbGV0aW9uAgAAABlfc3VydmV5X2hlaWdodF9jb21wbGV0aW9uAAAAAAxrU3VydmV5VGl0bGUCAAAADV9zdXJ2ZXlfdGl0bGUAAAAAEmtTdXJ2ZXlEZXNjcmlwdGlv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WJLZXkxU2lnbmVkBQAAABJhZG1pblB1YktleTJTaWduZWQFAAAAEmFkbWluUHViS2V5M1NpZ25lZAAAAAAAAAAAAq9cpNs=", "height": 2267763, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: none Next: 4dFyybK9k9XcDDixshUgsigT2Lj1fS4GxiKtBhcCqa69 Full:
OldNewDifferences
1-# no script
1+{-# STDLIB_VERSION 5 #-}
2+{-# SCRIPT_TYPE ACCOUNT #-}
3+{-# CONTENT_TYPE DAPP #-}
4+let a = "admin_pub_1"
5+
6+let b = "admin_pub_2"
7+
8+let c = "admin_pub_3"
9+
10+let d = "admin_invoke_pub"
11+
12+let e = "money_box_address"
13+
14+let f = "governance_address"
15+
16+let g = "active"
17+
18+let h = "last_survey_id"
19+
20+let i = "_survey_height_completion"
21+
22+let j = "_survey_title"
23+
24+let k = "_survey_description"
25+
26+let l = "_survey_option_name"
27+
28+let m = "_survey_option_type"
29+
30+let n = "_survey_user_vote"
31+
32+let o = "_survey_option_total_swop_voted"
33+
34+let p = "_SWOP_amount"
35+
36+let q = Address(base58'3MvVBtsXroQpy1tsPw21TU2ET9A8WfmrNjz')
37+
38+func r (s) = {
39+ let t = getString(q, s)
40+ if ($isInstanceOf(t, "String"))
41+ then {
42+ let u = t
43+ fromBase58String(u)
44+ }
45+ else {
46+ let v = t
47+ throw((s + "is empty"))
48+ }
49+ }
50+
51+
52+let w = r(a)
53+
54+let x = r(b)
55+
56+let y = r(c)
57+
58+let z = r(d)
59+
60+let A = Address(r(e))
61+
62+let B = Address(r(f))
63+
64+let C = valueOrElse(getBoolean(this, g), true)
65+
66+func D () = if (C)
67+ then unit
68+ else throw("DApp is inactive at this moment")
69+
70+
71+func E (F) = if (containsElement([w, x, y], F.callerPublicKey))
72+ then unit
73+ else throw("Only admin can call this function")
74+
75+
76+func G (F) = if ((A == F.caller))
77+ then unit
78+ else throw("Only Money box can call this function")
79+
80+
81+@Callable(F)
82+func initSurvey (H,I,J,K,L) = valueOrElse(D(), valueOrElse(E(F), if ((height >= H))
83+ then throw("Height of survey completion must be greater than currnet height")
84+ else if ((size(K) > 10))
85+ then throw("Max 10 options must be specified")
86+ else if ((size(K) != size(L)))
87+ then throw("Size of optionsTypes must be same as options")
88+ else {
89+ let M = (valueOrElse(getInteger(this, h), 0) + 1)
90+ func N (O,P) = {
91+ let Q = O
92+ let R = Q._1
93+ let S = Q._2
94+ let T = Q._3
95+ let U = ((T :+ StringEntry((((toString(M) + "_") + toString(S)) + l), P)) :+ StringEntry((((toString(M) + "_") + toString(S)) + m), R[S]))
96+ $Tuple3(R, (S + 1), U)
97+ }
98+
99+ let V = {
100+ let W = K
101+ let X = size(W)
102+ let Y = $Tuple3(L, 0, nil)
103+ func Z (aa,ab) = if ((ab >= X))
104+ then aa
105+ else N(aa, W[ab])
106+
107+ func ac (aa,ab) = if ((ab >= X))
108+ then aa
109+ else throw("List size exceeds 10")
110+
111+ ac(Z(Z(Z(Z(Z(Z(Z(Z(Z(Z(Y, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10)
112+ }
113+ ([IntegerEntry(h, M), IntegerEntry((toString(M) + i), H), StringEntry((toString(M) + j), I), StringEntry((toString(M) + k), J)] ++ V._3)
114+ }))
115+
116+
117+
118+@Callable(F)
119+func vote (ad,ae) = valueOrElse(D(), if (!(isDefined(getString(this, (toString(ad) + j)))))
120+ then throw(("There is no survey with id " + toString(ad)))
121+ else if (!(isDefined(getString(this, (((toString(ad) + "_") + toString(ae)) + l)))))
122+ then throw(((("There is no option " + toString(ae)) + " in survey ") + toString(ad)))
123+ else if (isDefined(getInteger(this, (((toString(ad) + "_") + toString(F.caller)) + n))))
124+ then throw("You can't vote twice")
125+ else if ((height > value(getInteger(this, (toString(ad) + i)))))
126+ then throw("Survey already end")
127+ else if ((0 >= valueOrElse(getInteger(B, (toString(F.caller) + p)), 0)))
128+ then throw("Stake swop in governance to survey")
129+ else [IntegerEntry((((toString(ad) + "_") + toString(F.caller)) + n), ae)])
130+
131+
132+
133+@Callable(F)
134+func writeTotals (ad,af) = valueOrElse(D(), valueOrElse(G(F), if (!(isDefined(getString(this, (toString(ad) + j)))))
135+ then throw(("There is no survey with id " + toString(ad)))
136+ else if ((value(getInteger(this, (toString(ad) + i))) > height))
137+ then throw("Survey is not ended yet")
138+ else {
139+ func ag (O,ah) = {
140+ let ai = O
141+ let ae = ai._1
142+ let T = ai._2
143+ let U = (T :+ IntegerEntry((((toString(ad) + "_") + toString(ae)) + o), ah))
144+ $Tuple2((ae + 1), U)
145+ }
146+
147+ let V = {
148+ let W = af
149+ let X = size(W)
150+ let Y = $Tuple2(0, nil)
151+ func Z (aa,ab) = if ((ab >= X))
152+ then aa
153+ else ag(aa, W[ab])
154+
155+ func ac (aa,ab) = if ((ab >= X))
156+ then aa
157+ else throw("List size exceeds 10")
158+
159+ ac(Z(Z(Z(Z(Z(Z(Z(Z(Z(Z(Y, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10)
160+ }
161+ V._2
162+ }))
163+
164+
165+@Verifier(aj)
166+func ak () = {
167+ let al = if (sigVerify(aj.bodyBytes, aj.proofs[0], w))
168+ then 1
169+ else 0
170+ let am = if (sigVerify(aj.bodyBytes, aj.proofs[1], x))
171+ then 1
172+ else 0
173+ let an = if (sigVerify(aj.bodyBytes, aj.proofs[2], y))
174+ then 1
175+ else 0
176+ (((al + am) + an) >= 2)
177+ }
178+

github/deemru/w8io/169f3d6 
23.78 ms