tx · Ey8Cpyh5jrrMFHAcGHSYRjzHyrCKoJW25QDaFHnstG24 3N8RGScPyKYySaXd5Z3VcpnttH2uBeMpSy4: -0.01400000 Waves 2020.03.14 23:24 [909344] smart account 3N8RGScPyKYySaXd5Z3VcpnttH2uBeMpSy4 > SELF 0.00000000 Waves
{ "type": 13, "id": "Ey8Cpyh5jrrMFHAcGHSYRjzHyrCKoJW25QDaFHnstG24", "fee": 1400000, "feeAssetId": null, "timestamp": 1584217430326, "version": 1, "sender": "3N8RGScPyKYySaXd5Z3VcpnttH2uBeMpSy4", "senderPublicKey": "4AHsCbS9QYVdKNvxrPWwsMwwy3KqXaCMXeAscExJZk9L", "proofs": [ "5tjrfG9P5YHrjiCQf4ibrNFfwGH3V8wie6kW2r39CxbkLk9JZutAgkhXnwwMS8ok6FLKFx2vZm8pM3pnQtwWn8WX" ], "script": "base64:AAIDAAAAAAAAABQIARIGCgQIAQEIEggKBggICAEBAQAAAB0AAAAAB2FCaXRDTzIBAAAAIMf4egCdN1CfKjJsuySIc91YzhODi96HwhotKBtnwSiWAAAAAAhzdGFydFF0eQAAAAAAAAUUAAAAAAAIbm9tUHJpY2UAAAAAAAX14QAAAAAAEHN1cHBsaWVyRGlzY291bnQAAAAAAAAAAAwAAAAADk93bmVyRWNvUHViS2V5AQAAACAu9FujQAkaDvA3MFtEeOs3vmzRi69LYN3AJDT/FjZAHwAAAAADd3ZzAAAAAAAF9eEAAAAAAAROT05FAgAAAARub25lAAAAAAZpc3N1ZXIJAQAAAAdBZGRyZXNzAAAAAQEAAAAaAVTK9zs+5y/RVeIPrfhFsyze+43QDUVrfW8BAAAADmdldE51bWJlckJ5S2V5AAAAAQAAAANrZXkEAAAAA251bQQAAAAHJG1hdGNoMAkABBoAAAACBQAAAAR0aGlzBQAAAANrZXkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAA0ludAQAAAABYQUAAAAHJG1hdGNoMAUAAAABYQAAAAAAAAAAAAUAAAADbnVtAQAAAAtnZXRTd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CQAAZwAAAAIIBQAAAAJ0eAAAAAZhbW91bnQFAAAACW1pbkFtb3VudAcJAABnAAAAAgUAAAAJbWF4QW1vdW50CAUAAAACdHgAAAAGYW1vdW50BwYJAAACAAAAAQIAAABTRXJyb3I6IE1pbmltdW0gYW1vdW50OiAxIGFCaXRDTzI7IE1heGltdW0gYW1vdW50IG9mZmVyZWQ6IDQgYUJpdENPMiBieSBVc2VyIEFjY291bnQHAwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAABdJbnZva2VTY3JpcHRUcmFuc2FjdGlvbgQAAAABYwUAAAAHJG1hdGNoMAYHSVtbHQ==", "chainId": 84, "height": 909344, "spentComplexity": 0 } View: original | compacted Prev: DqmJCDiiSeUxPN898VyRzjHHKGT8kRWvK7e92U8hjJ73 Next: 8m3Ec5vuZS77HxjaByt6d3w2mbTtu4xzGhayMX2vyRDY Diff:
Old | New | Differences | |
---|---|---|---|
153 | 153 | then throw("Payment Amount cannot be less than item Purchase Order") | |
154 | 154 | else if ((U.amount > Y)) | |
155 | 155 | then throw("Payment Amount can't be higher than item Purchase Order") | |
156 | - | else ScriptResult(WriteSet([DataEntry(y(W, t), (A(W, t) + 1)), DataEntry(G(t), P), DataEntry(v(t), (N - S)), DataEntry(B(t), Q), DataEntry((("Descuento solicitado:_" + W) + "_%"), R), DataEntry(("Cantidad_solicitada:" + C(t)), S), DataEntry((("Monto pagado:_" + W) + "_waves"), T), DataEntry(("Request_Status:_" + W), "confirmed"), DataEntry(E(q), (V + U.amount))]), TransferSet([ScriptTransfer(addressFromStringValue( | |
156 | + | else ScriptResult(WriteSet([DataEntry(y(W, t), (A(W, t) + 1)), DataEntry(G(t), P), DataEntry(v(t), (N - S)), DataEntry(B(t), Q), DataEntry((("Descuento solicitado:_" + W) + "_%"), R), DataEntry(("Cantidad_solicitada:" + C(t)), S), DataEntry((("Monto pagado:_" + W) + "_waves"), T), DataEntry(("Request_Status:_" + W), "confirmed"), DataEntry(E(q), (V + U.amount))]), TransferSet([ScriptTransfer(addressFromStringValue(W), S, a)])) | |
157 | 157 | } | |
158 | 158 | } | |
159 | 159 |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 3 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let a = base58'ETbtNp6MBuSM9EfjmLDwctrYEBBiq8CZ7ti7zbwTktry' | |
5 | 5 | ||
6 | 6 | let b = 332800 | |
7 | 7 | ||
8 | 8 | let c = 100000000 | |
9 | 9 | ||
10 | 10 | let d = 12 | |
11 | 11 | ||
12 | 12 | let e = base58'4AHsCbS9QYVdKNvxrPWwsMwwy3KqXaCMXeAscExJZk9L' | |
13 | 13 | ||
14 | 14 | let f = 100000000 | |
15 | 15 | ||
16 | 16 | let g = "none" | |
17 | 17 | ||
18 | 18 | let h = Address(base58'3N8RGScPyKYySaXd5Z3VcpnttH2uBeMpSy4') | |
19 | 19 | ||
20 | 20 | func i (j) = { | |
21 | 21 | let k = { | |
22 | 22 | let l = getInteger(this, j) | |
23 | 23 | if ($isInstanceOf(l, "Int")) | |
24 | 24 | then { | |
25 | 25 | let m = l | |
26 | 26 | m | |
27 | 27 | } | |
28 | 28 | else 0 | |
29 | 29 | } | |
30 | 30 | k | |
31 | 31 | } | |
32 | 32 | ||
33 | 33 | ||
34 | 34 | func n (j) = { | |
35 | 35 | let o = { | |
36 | 36 | let l = getString(this, j) | |
37 | 37 | if ($isInstanceOf(l, "String")) | |
38 | 38 | then { | |
39 | 39 | let m = l | |
40 | 40 | m | |
41 | 41 | } | |
42 | 42 | else g | |
43 | 43 | } | |
44 | 44 | o | |
45 | 45 | } | |
46 | 46 | ||
47 | 47 | ||
48 | 48 | func p (q,r) = ("tokens_Bit-CO2:_" + toBase58String(sha256(toBytes((q + r))))) | |
49 | 49 | ||
50 | 50 | ||
51 | 51 | func s (t) = (t + "_to_Amazonian_Conservation") | |
52 | 52 | ||
53 | 53 | ||
54 | 54 | func u (t) = n(s(t)) | |
55 | 55 | ||
56 | 56 | ||
57 | 57 | func v (t) = "Tokens_ofertados,_Saldo" | |
58 | 58 | ||
59 | 59 | ||
60 | 60 | func w (t) = i(v(t)) | |
61 | 61 | ||
62 | 62 | ||
63 | 63 | func x (t) = (t + "_description") | |
64 | 64 | ||
65 | 65 | ||
66 | 66 | func y (z,t) = (((t + "_") + z) + "_cnt") | |
67 | 67 | ||
68 | 68 | ||
69 | 69 | func A (z,t) = i(y(z, t)) | |
70 | 70 | ||
71 | 71 | ||
72 | 72 | func B (t) = "_userdata" | |
73 | 73 | ||
74 | 74 | ||
75 | 75 | func C (t) = "_tokens" | |
76 | 76 | ||
77 | 77 | ||
78 | 78 | func D (t) = i(C(t)) | |
79 | 79 | ||
80 | 80 | ||
81 | 81 | func E (q) = "Seller_Balance:_waves" | |
82 | 82 | ||
83 | 83 | ||
84 | 84 | func F (q) = i(E(q)) | |
85 | 85 | ||
86 | 86 | ||
87 | 87 | func G (t) = "Project_name:" | |
88 | 88 | ||
89 | 89 | ||
90 | 90 | func H (t) = n(G(t)) | |
91 | 91 | ||
92 | 92 | ||
93 | 93 | func I (t) = "_%" | |
94 | 94 | ||
95 | 95 | ||
96 | 96 | func J (t) = i(I(t)) | |
97 | 97 | ||
98 | 98 | ||
99 | 99 | func K (t) = "_waves" | |
100 | 100 | ||
101 | 101 | ||
102 | 102 | func L (t) = i(K(t)) | |
103 | 103 | ||
104 | 104 | ||
105 | 105 | @Callable(M) | |
106 | 106 | func AddSupplierToken (r,N,d,O) = { | |
107 | 107 | let q = toBase58String(M.caller.bytes) | |
108 | 108 | let t = p(q, r) | |
109 | 109 | if ((0 >= N)) | |
110 | 110 | then throw("Sorry, insufficient token offer") | |
111 | 111 | else WriteSet([DataEntry(("Ofertante:_" + s(t)), q), DataEntry(v(t), N), DataEntry(("Precio_Nominal:" + K(t)), c), DataEntry(("Max_Descuento_ofrecido:" + I(t)), d), DataEntry(x(t), O)]) | |
112 | 112 | } | |
113 | 113 | ||
114 | 114 | ||
115 | 115 | ||
116 | 116 | @Callable(M) | |
117 | 117 | func purchase (t,P,Q,R,S,T) = { | |
118 | 118 | let U = extract(M.payment) | |
119 | 119 | if (isDefined(U.assetId)) | |
120 | 120 | then throw("you can adquire cBitCO2 only by Waves tokens") | |
121 | 121 | else { | |
122 | 122 | let q = { | |
123 | 123 | let l = getString(this, s(t)) | |
124 | 124 | if ($isInstanceOf(l, "String")) | |
125 | 125 | then { | |
126 | 126 | let m = l | |
127 | 127 | m | |
128 | 128 | } | |
129 | 129 | else g | |
130 | 130 | } | |
131 | 131 | let N = { | |
132 | 132 | let l = getInteger(this, v(t)) | |
133 | 133 | if ($isInstanceOf(l, "Int")) | |
134 | 134 | then { | |
135 | 135 | let m = l | |
136 | 136 | m | |
137 | 137 | } | |
138 | 138 | else b | |
139 | 139 | } | |
140 | 140 | let V = { | |
141 | 141 | let l = getInteger(this, E(q)) | |
142 | 142 | if ($isInstanceOf(l, "Int")) | |
143 | 143 | then { | |
144 | 144 | let m = l | |
145 | 145 | m | |
146 | 146 | } | |
147 | 147 | else 0 | |
148 | 148 | } | |
149 | 149 | let W = toBase58String(M.caller.bytes) | |
150 | 150 | let X = ((c * (100 - R)) / 100) | |
151 | 151 | let Y = (S * X) | |
152 | 152 | if ((Y > U.amount)) | |
153 | 153 | then throw("Payment Amount cannot be less than item Purchase Order") | |
154 | 154 | else if ((U.amount > Y)) | |
155 | 155 | then throw("Payment Amount can't be higher than item Purchase Order") | |
156 | - | else ScriptResult(WriteSet([DataEntry(y(W, t), (A(W, t) + 1)), DataEntry(G(t), P), DataEntry(v(t), (N - S)), DataEntry(B(t), Q), DataEntry((("Descuento solicitado:_" + W) + "_%"), R), DataEntry(("Cantidad_solicitada:" + C(t)), S), DataEntry((("Monto pagado:_" + W) + "_waves"), T), DataEntry(("Request_Status:_" + W), "confirmed"), DataEntry(E(q), (V + U.amount))]), TransferSet([ScriptTransfer(addressFromStringValue( | |
156 | + | else ScriptResult(WriteSet([DataEntry(y(W, t), (A(W, t) + 1)), DataEntry(G(t), P), DataEntry(v(t), (N - S)), DataEntry(B(t), Q), DataEntry((("Descuento solicitado:_" + W) + "_%"), R), DataEntry(("Cantidad_solicitada:" + C(t)), S), DataEntry((("Monto pagado:_" + W) + "_waves"), T), DataEntry(("Request_Status:_" + W), "confirmed"), DataEntry(E(q), (V + U.amount))]), TransferSet([ScriptTransfer(addressFromStringValue(W), S, a)])) | |
157 | 157 | } | |
158 | 158 | } | |
159 | 159 | ||
160 | 160 | ||
161 | 161 | @Verifier(Z) | |
162 | 162 | func aa () = { | |
163 | 163 | let l = Z | |
164 | 164 | if ($isInstanceOf(l, "SetScriptTransaction")) | |
165 | 165 | then { | |
166 | 166 | let ab = l | |
167 | 167 | sigVerify(Z.bodyBytes, Z.proofs[0], e) | |
168 | 168 | } | |
169 | 169 | else if ($isInstanceOf(l, "DataTransaction")) | |
170 | 170 | then { | |
171 | 171 | let ac = l | |
172 | 172 | true | |
173 | 173 | } | |
174 | 174 | else if ($isInstanceOf(l, "TransferTransaction")) | |
175 | 175 | then { | |
176 | 176 | let Z = l | |
177 | 177 | let ad = toBase58String(addressFromRecipient(Z.recipient).bytes) | |
178 | 178 | if ((Z.sender == h)) | |
179 | 179 | then true | |
180 | 180 | else throw("You can't transferred this token") | |
181 | 181 | } | |
182 | 182 | else if ($isInstanceOf(l, "ExchangeTransaction")) | |
183 | 183 | then { | |
184 | 184 | let Z = l | |
185 | 185 | let ae = if (!(isDefined(Z.sellOrder.assetPair.priceAsset))) | |
186 | 186 | then true | |
187 | 187 | else !(isDefined(Z.sellOrder.assetPair.amountAsset)) | |
188 | 188 | ae | |
189 | 189 | } | |
190 | 190 | else if ($isInstanceOf(l, "ExchangeTransaction")) | |
191 | 191 | then { | |
192 | 192 | let Z = l | |
193 | 193 | let af = Z.proofs[1] | |
194 | 194 | let ag = addressFromPublicKey(af) | |
195 | 195 | let ah = 1400000 | |
196 | 196 | let ai = ((wavesBalance(ag) - ah) >= Z.buyOrder.price) | |
197 | 197 | let aj = sigVerify(Z.sellOrder.bodyBytes, Z.sellOrder.proofs[0], Z.sellOrder.senderPublicKey) | |
198 | 198 | let ak = sigVerify(Z.buyOrder.bodyBytes, Z.buyOrder.proofs[0], Z.buyOrder.senderPublicKey) | |
199 | 199 | let al = toBase58String(Z.sellOrder.sender.bytes) | |
200 | 200 | let am = 1 | |
201 | 201 | let an = 4 | |
202 | 202 | let ao = (an * c) | |
203 | 203 | if (if (ak) | |
204 | 204 | then if (isDefined((ao >= Z.buyOrder.price))) | |
205 | 205 | then true | |
206 | 206 | else throw("El monto a pagar no puede ser menor que el precio de venta") | |
207 | 207 | else false) | |
208 | 208 | then true | |
209 | 209 | else if (aj) | |
210 | 210 | then if (if (if ((Z.sellOrder.sender == h)) | |
211 | 211 | then (Z.amount >= am) | |
212 | 212 | else false) | |
213 | 213 | then (an >= Z.amount) | |
214 | 214 | else false) | |
215 | 215 | then true | |
216 | 216 | else throw("Error: Minimum amount: 1 aBitCO2; Maximum amount offered: 4 aBitCO2 by User Account") | |
217 | 217 | else false | |
218 | 218 | } | |
219 | 219 | else if ($isInstanceOf(l, "InvokeScriptTransaction")) | |
220 | 220 | then { | |
221 | 221 | let ap = l | |
222 | 222 | true | |
223 | 223 | } | |
224 | 224 | else false | |
225 | 225 | } | |
226 | 226 |
github/deemru/w8io/169f3d6 40.37 ms ◑