tx · 4y8mgbkhuMgVNkCJ8VnMzgoNS4Zw4x3LgwVHzPsR8XzM 3MvRNiiunRy51KJXcLmZhUzrm9fXfMcapuB: -0.10650000 Waves 2021.05.20 11:19 [1533746] smart account 3MvRNiiunRy51KJXcLmZhUzrm9fXfMcapuB > SELF 0.00000000 Waves
{ "type": 13, "id": "4y8mgbkhuMgVNkCJ8VnMzgoNS4Zw4x3LgwVHzPsR8XzM", "fee": 10650000, "feeAssetId": null, "timestamp": 1621498770511, "version": 2, "chainId": 84, "sender": "3MvRNiiunRy51KJXcLmZhUzrm9fXfMcapuB", "senderPublicKey": "AJhgEzWrvQYvLJdZ4bDYWy3W5H1h7UqSPwUyzSKsTYuh", "proofs": [ "EnH1KrUKzTpoXehXrJ7ZiDDFoXv6dq9cdbhFWEB3nkZZZBVMXTaZA8sU3sSPpusrryG1DtmrBEgBjuc6K2yQzHh" ], "script": "base64:AAIDAAAAAAAAACEIARIDCgEIEgMKAQgSAwoBCBIDCgEIEgMKAQgSBAoCCAgAAAAKAQAAAAx0cnlHZXRTdHJpbmcAAAABAAAAA2tleQQAAAADdmFsBAAAAAckbWF0Y2gwCQAEHQAAAAIFAAAABHRoaXMFAAAAA2tleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAGU3RyaW5nBAAAAAFiBQAAAAckbWF0Y2gwBQAAAAFiAgAAAAAFAAAAA3ZhbAEAAAAJaXNNYW5hZ2VyAAAAAQAAAAdhZGRyZXNzCQAAAAAAAAIFAAAAB2FkZHJlc3MFAAAABHRoaXMBAAAADXRyeUdldEludGVnZXIAAAABAAAAA2tleQQAAAADdmFsBAAAAAckbWF0Y2gwCQAEGgAAAAIFAAAABHRoaXMFAAAAA2tleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAADSW50BAAAAAFiBQAAAAckbWF0Y2gwBQAAAAFiAAAAAAAAAAAABQAAAAN2YWwBAAAAGGlzTWVtYmVyc2hpcFdvcmtpbmdHcm91cAAAAAEAAAABYQkAAAAAA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==", "height": 1533746, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: F842c7KVBcC5ZbSDz6Ko4yzAk9JTKtZQHDXokCMw6qgG Next: 9GNz3y9KeuLoGBkxksr8kqkUbuw9ESoMgGH6fLKxcg7n Diff:
Old | New | Differences | |
---|---|---|---|
128 | 128 | let v = ((u + ";") + g) | |
129 | 129 | let w = h("dao_wg_size") | |
130 | 130 | let x = (w + 1) | |
131 | - | WriteSet([DataEntry((("dao_wg_" + g) + "_status"), "approved"), DataEntry("dao_wg_members", v), DataEntry("dao_wg_size", x)]) | |
131 | + | WriteSet([DataEntry((("dao_wg_member_" + g) + "_status"), "approved"), DataEntry("dao_wg_members", v), DataEntry("dao_wg_size", x)]) | |
132 | 132 | } | |
133 | 133 | ||
134 | 134 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 3 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | func a (b) = { | |
5 | 5 | let c = { | |
6 | 6 | let d = getString(this, b) | |
7 | 7 | if ($isInstanceOf(d, "String")) | |
8 | 8 | then { | |
9 | 9 | let e = d | |
10 | 10 | e | |
11 | 11 | } | |
12 | 12 | else "" | |
13 | 13 | } | |
14 | 14 | c | |
15 | 15 | } | |
16 | 16 | ||
17 | 17 | ||
18 | 18 | func f (g) = (g == this) | |
19 | 19 | ||
20 | 20 | ||
21 | 21 | func h (b) = { | |
22 | 22 | let c = { | |
23 | 23 | let d = getInteger(this, b) | |
24 | 24 | if ($isInstanceOf(d, "Int")) | |
25 | 25 | then { | |
26 | 26 | let e = d | |
27 | 27 | e | |
28 | 28 | } | |
29 | 29 | else 0 | |
30 | 30 | } | |
31 | 31 | c | |
32 | 32 | } | |
33 | 33 | ||
34 | 34 | ||
35 | 35 | func i (j) = (a((("membership_" + toString(j)) + "_status")) == "approved") | |
36 | 36 | ||
37 | 37 | ||
38 | 38 | func k (j) = (a((("working_group_" + toString(j)) + "_status")) == "approved") | |
39 | 39 | ||
40 | 40 | ||
41 | 41 | func l (j) = (a((("dao_member_" + toString(j)) + "_status")) == "approved") | |
42 | 42 | ||
43 | 43 | ||
44 | 44 | func m (n,o) = (h(((n + "_voted_") + o)) > 0) | |
45 | 45 | ||
46 | 46 | ||
47 | 47 | func p () = { | |
48 | 48 | let c = { | |
49 | 49 | let d = getString(this, "dao_members") | |
50 | 50 | if ($isInstanceOf(d, "String")) | |
51 | 51 | then { | |
52 | 52 | let e = d | |
53 | 53 | e | |
54 | 54 | } | |
55 | 55 | else "" | |
56 | 56 | } | |
57 | 57 | c | |
58 | 58 | } | |
59 | 59 | ||
60 | 60 | ||
61 | 61 | func q () = { | |
62 | 62 | let c = { | |
63 | 63 | let d = getString(this, "membership_working_group_members") | |
64 | 64 | if ($isInstanceOf(d, "String")) | |
65 | 65 | then { | |
66 | 66 | let e = d | |
67 | 67 | e | |
68 | 68 | } | |
69 | 69 | else "" | |
70 | 70 | } | |
71 | 71 | c | |
72 | 72 | } | |
73 | 73 | ||
74 | 74 | ||
75 | 75 | func r (s) = if ((s == "like")) | |
76 | 76 | then 1 | |
77 | 77 | else if ((s == "dislike")) | |
78 | 78 | then -1 | |
79 | 79 | else throw(("You need to vote with 'like' or 'dislike' value. You specified:" + s)) | |
80 | 80 | ||
81 | 81 | ||
82 | 82 | @Callable(t) | |
83 | 83 | func aProposeCandidateForDAOMember (g) = if ((h((("member_" + g) + "_voting_state")) != 0)) | |
84 | 84 | then throw("This user already exists") | |
85 | 85 | else { | |
86 | 86 | let u = p() | |
87 | 87 | let v = ((u + ";") + g) | |
88 | 88 | let w = h("dao_members_size") | |
89 | 89 | let x = (w + 1) | |
90 | 90 | WriteSet([DataEntry((("dao_member_" + g) + "_status"), "propose"), DataEntry("dao_members", v), DataEntry("dao_members_size", x)]) | |
91 | 91 | } | |
92 | 92 | ||
93 | 93 | ||
94 | 94 | ||
95 | 95 | @Callable(t) | |
96 | 96 | func mRejectDAOMember (g) = if (!(f(t.caller))) | |
97 | 97 | then throw("access only to the DAO Manager") | |
98 | 98 | else WriteSet([DataEntry((("dao_member_" + g) + "_status"), "rejected")]) | |
99 | 99 | ||
100 | 100 | ||
101 | 101 | ||
102 | 102 | @Callable(t) | |
103 | 103 | func mAddDAOMember (g) = if (!(f(t.caller))) | |
104 | 104 | then throw("access only to the DAO Manager") | |
105 | 105 | else { | |
106 | 106 | let u = p() | |
107 | 107 | let v = ((u + ";") + g) | |
108 | 108 | let w = h("dao_members_size") | |
109 | 109 | let x = (w + 1) | |
110 | 110 | WriteSet([DataEntry((("dao_member_" + g) + "_status"), "approved"), DataEntry("dao_members", v), DataEntry("dao_members_size", x)]) | |
111 | 111 | } | |
112 | 112 | ||
113 | 113 | ||
114 | 114 | ||
115 | 115 | @Callable(t) | |
116 | 116 | func mAddWorkingGroup (g) = if (!(f(t.caller))) | |
117 | 117 | then throw("access only to the DAO Manager") | |
118 | 118 | else { | |
119 | 119 | let u = { | |
120 | 120 | let d = getString(this, "dao_wg_members") | |
121 | 121 | if ($isInstanceOf(d, "String")) | |
122 | 122 | then { | |
123 | 123 | let e = d | |
124 | 124 | e | |
125 | 125 | } | |
126 | 126 | else "" | |
127 | 127 | } | |
128 | 128 | let v = ((u + ";") + g) | |
129 | 129 | let w = h("dao_wg_size") | |
130 | 130 | let x = (w + 1) | |
131 | - | WriteSet([DataEntry((("dao_wg_" + g) + "_status"), "approved"), DataEntry("dao_wg_members", v), DataEntry("dao_wg_size", x)]) | |
131 | + | WriteSet([DataEntry((("dao_wg_member_" + g) + "_status"), "approved"), DataEntry("dao_wg_members", v), DataEntry("dao_wg_size", x)]) | |
132 | 132 | } | |
133 | 133 | ||
134 | 134 | ||
135 | 135 | ||
136 | 136 | @Callable(t) | |
137 | 137 | func mAddMembershipWorkingGroup (g) = if (!(f(t.caller))) | |
138 | 138 | then throw("access only to the DAO Manager") | |
139 | 139 | else { | |
140 | 140 | let u = q() | |
141 | 141 | let v = ((u + ";") + g) | |
142 | 142 | let w = h("membership_working_group_members_size") | |
143 | 143 | let x = (w + 1) | |
144 | 144 | WriteSet([DataEntry((("membership_" + g) + "_status"), "approved"), DataEntry("membership_working_group_members", v), DataEntry("membership_working_group_members_size", x)]) | |
145 | 145 | } | |
146 | 146 | ||
147 | 147 | ||
148 | 148 | ||
149 | 149 | @Callable(t) | |
150 | 150 | func wmgMembershipVoteForDAOMember (o,y) = { | |
151 | 151 | let n = toString(t.caller) | |
152 | 152 | let z = r(y) | |
153 | 153 | let A = (("dao_member_" + o) + "_vote") | |
154 | 154 | let B = (("dao_member_" + o) + "_voted") | |
155 | 155 | let C = { | |
156 | 156 | let d = getString(this, B) | |
157 | 157 | if ($isInstanceOf(d, "String")) | |
158 | 158 | then { | |
159 | 159 | let e = d | |
160 | 160 | e | |
161 | 161 | } | |
162 | 162 | else "" | |
163 | 163 | } | |
164 | 164 | let D = h(A) | |
165 | 165 | let E = (D + z) | |
166 | 166 | if (i(t.caller)) | |
167 | 167 | then if (m(n, o)) | |
168 | 168 | then throw("You have already voted") | |
169 | 169 | else WriteSet([DataEntry(((n + "_voted_") + o), 1), DataEntry(A, E), DataEntry(B, C)]) | |
170 | 170 | else throw("You have no rights") | |
171 | 171 | } | |
172 | 172 | ||
173 | 173 |
github/deemru/w8io/026f985 31.30 ms ◑