tx · Atw1mY2PkAnrYuQrUPX2XobfSXsRpW5qVtrGGxRfNHdj 3Mzms5gHUDYufDRjSVN7g9DcCMG77pzFN4h: -0.01400000 Waves 2021.09.29 08:40 [1723827] smart account 3Mzms5gHUDYufDRjSVN7g9DcCMG77pzFN4h > SELF 0.00000000 Waves
{ "type": 13, "id": "Atw1mY2PkAnrYuQrUPX2XobfSXsRpW5qVtrGGxRfNHdj", "fee": 1400000, "feeAssetId": null, "timestamp": 1632894087243, "version": 2, "chainId": 84, "sender": "3Mzms5gHUDYufDRjSVN7g9DcCMG77pzFN4h", "senderPublicKey": "CU8dJ2mJQjVBWaDHwXjPztuVdy9XAyAnTuqSCKuNPARn", "proofs": [ "2aNTeDzRnK9SF6WQs7dp8cKEi7UviyJr9GwGvKsjUaKYQLs2WiesdLL9vKeYk6CyBYyUUZ9WcZNs7xxY8FQGh4Ly" ], "script": "base64:AAIFAAAAAAAAAB0IAhIDCgEBEgASBwoFCAgICAgSBAoCCAgSAwoBCAAAABMAAAAAD3N0b3JhZ2VWZXJpZmllcgkBAAAABXZhbHVlAAAAAQkABCYAAAABAgAAACMzTjJzNVJ0YUhQQmVuQ3N4MkVDY29GUmJZSHgzbm9aaFhXMQAAAAAJc2lnbkFkbWluAgAAACMzTjF3UGdIRnRlem1SVkJhcW9valA4WEp3VGthcms0aGJpZgAAAAAIZmVlQWRtaW4CAAAAIzNOMXdQZ0hGdGV6bVJWQmFxb29qUDhYSndUa2FyazRoYmlmAAAAAARiYW5rAgAAACMzTjFFNnRYZGRSb1ZhUmZROWRRM3ZnNUxhVzJmc2Q4SEt1YgAAAAAJc2lnblRva2VuAQAAACDopWq8yndC8nBhMjVKT0WDubke5ZlnF8Nx6tkLoQSt6wAAAAANYWNjZXB0ZWRUb2tlbgEAAAAgYfHkwqhFFD81I1SLw0GO/ozjwqWx6THXqSKcOOhu9fcAAAAABnVzZG5JRAIAAAAsM0tGWEJHR0xDakE1WjJEdVc0RHE5ZkREckhqSkpQMVpFa2Fv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YmxpY0tleQMJAAAAAAAAAgUAAAAGY2FsbGVyBQAAAAlzaWduQWRtaW4JAARMAAAAAgkBAAAAC0RlbGV0ZUVudHJ5AAAAAQUAAAAFZW50cnkFAAAAA25pbAkAAAIAAAABAgAAAAJubwAAAAA0uZgJ", "height": 1723827, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 7tR92wrGrPZnQmj3JSivqhxHn2mdsrxvaatQfRzsQ7qj Next: FM7oQEjeePCqXvW5bg3bghixggux158zh2WdCWfeHLX Diff:
Old | New | Differences | |
---|---|---|---|
116 | 116 | else { | |
117 | 117 | let currentSIGNPrice = getIntegerValue(storageVerifier, ("certification_fee_" + toBase58String(value(paymentAssetId)))) | |
118 | 118 | if (true) | |
119 | - | then throw(("Uy! " + toString( | |
119 | + | then throw(("Uy! " + toString((amount * 100000000)))) | |
120 | 120 | else { | |
121 | - | let numCredit = (currentSIGNPrice / amount) | |
121 | + | let numCredit = (currentSIGNPrice / (amount * 100000000)) | |
122 | 122 | if ((0 >= numCredit)) | |
123 | 123 | then throw("Not enough for at least 1 credit") | |
124 | 124 | else [IntegerEntry(("credits_" + toBase58String(acceptedToken)), numCredit), ScriptTransfer(addressFromStringValue(signDapp), amount, payment.assetId)] |
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 5 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | let storageVerifier = value(addressFromString("3N2s5RtaHPBenCsx2ECcoFRbYHx3noZhXW1")) | |
5 | 5 | ||
6 | 6 | let signAdmin = "3N1wPgHFtezmRVBaqoojP8XJwTkark4hbif" | |
7 | 7 | ||
8 | 8 | let feeAdmin = "3N1wPgHFtezmRVBaqoojP8XJwTkark4hbif" | |
9 | 9 | ||
10 | 10 | let bank = "3N1E6tXddRoVaRfQ9dQ3vg5LaW2fsd8HKub" | |
11 | 11 | ||
12 | 12 | let signToken = base58'Gf9t8FA4H3ssoZPCwrg3KwUFCci8zuUFP9ssRsUY3s6a' | |
13 | 13 | ||
14 | 14 | let acceptedToken = base58'7bLUm2XNLWvVwgC9aPp9fNNAMVtbGwhwkqdgomJAgVbC' | |
15 | 15 | ||
16 | 16 | let usdnID = "3KFXBGGLCjA5Z2DuW4Dq9fDDrHjJJP1ZEkaoajSzuKsC" | |
17 | 17 | ||
18 | 18 | let signDapp = "3N1E6tXddRoVaRfQ9dQ3vg5LaW2fsd8HKub" | |
19 | 19 | ||
20 | 20 | func getIntegerByKey (key) = valueOrElse(getInteger(this, key), 0) | |
21 | 21 | ||
22 | 22 | ||
23 | 23 | func checkEntry (prefix,uuid) = match getString(this, (prefix + uuid)) { | |
24 | 24 | case a: String => | |
25 | 25 | a | |
26 | 26 | case _ => | |
27 | 27 | "NONE" | |
28 | 28 | } | |
29 | 29 | ||
30 | 30 | ||
31 | 31 | func checkEntryEmail (uuid,domain) = match getString(this, ((uuid + "@") + domain)) { | |
32 | 32 | case a: String => | |
33 | 33 | a | |
34 | 34 | case _ => | |
35 | 35 | "NONE" | |
36 | 36 | } | |
37 | 37 | ||
38 | 38 | ||
39 | 39 | func checkUUID (uuid) = match getString(this, uuid) { | |
40 | 40 | case a: String => | |
41 | 41 | a | |
42 | 42 | case _ => | |
43 | 43 | "NONE" | |
44 | 44 | } | |
45 | 45 | ||
46 | 46 | ||
47 | 47 | func isAdress (addr) = if (if (if ((size(addr) == 35)) | |
48 | 48 | then (take(addr, 2) == "3P") | |
49 | 49 | else false) | |
50 | 50 | then true | |
51 | 51 | else (take(addr, 2) == "3N")) | |
52 | 52 | then true | |
53 | 53 | else (take(addr, 2) == "3M") | |
54 | 54 | ||
55 | 55 | ||
56 | 56 | func countParties (accumulator,addr) = if ((size(addr) > 0)) | |
57 | 57 | then (accumulator + 1) | |
58 | 58 | else (accumulator + 0) | |
59 | 59 | ||
60 | 60 | ||
61 | 61 | func checkIfPendingToSign (key) = match getString(this, key) { | |
62 | 62 | case a: String => | |
63 | 63 | if ((a == "PENDING")) | |
64 | 64 | then true | |
65 | 65 | else false | |
66 | 66 | case _ => | |
67 | 67 | false | |
68 | 68 | } | |
69 | 69 | ||
70 | 70 | ||
71 | 71 | func getValueString (json) = take(drop(json, 1), value(indexOf(drop(json, 1), "\""))) | |
72 | 72 | ||
73 | 73 | ||
74 | 74 | func getValue (json,key) = { | |
75 | 75 | let keyIndex = value(indexOf(json, (("\"" + key) + "\":"))) | |
76 | 76 | let data = drop(json, ((keyIndex + size(key)) + 3)) | |
77 | 77 | let jsonValue = getValueString(data) | |
78 | 78 | jsonValue | |
79 | 79 | } | |
80 | 80 | ||
81 | 81 | ||
82 | 82 | func getJsonBeforeValue (json,key) = { | |
83 | 83 | let keyIndex = value(indexOf(json, (("\"" + key) + "\":"))) | |
84 | 84 | let data = take(json, ((keyIndex + size(key)) + 3)) | |
85 | 85 | data | |
86 | 86 | } | |
87 | 87 | ||
88 | 88 | ||
89 | 89 | func getJsonAfterValue (json,key) = { | |
90 | 90 | let keyIndex = value(indexOf(json, (("\"" + key) + "\":"))) | |
91 | 91 | let data = takeRight(json, (size(json) - ((((keyIndex + size(key)) + 3) + 0) + 2))) | |
92 | 92 | data | |
93 | 93 | } | |
94 | 94 | ||
95 | 95 | ||
96 | 96 | @Callable(i) | |
97 | 97 | func setFee (fee) = { | |
98 | 98 | let callerAddress = toBase58String(i.caller.bytes) | |
99 | 99 | if ((callerAddress == feeAdmin)) | |
100 | 100 | then [IntegerEntry(("certification_fee_" + toBase58String(acceptedToken)), fee)] | |
101 | 101 | else throw("You are not allowed to change fee") | |
102 | 102 | } | |
103 | 103 | ||
104 | 104 | ||
105 | 105 | ||
106 | 106 | @Callable(i) | |
107 | 107 | func refillCredits () = { | |
108 | 108 | let callerAddress = toBase58String(i.caller.bytes) | |
109 | 109 | let payment = value(i.payments[0]) | |
110 | 110 | let amount = value(payment.amount) | |
111 | 111 | let paymentAssetId = if (isDefined(payment.assetId)) | |
112 | 112 | then value(payment.assetId) | |
113 | 113 | else throw("Accept SIGN token only") | |
114 | 114 | if ((signToken != paymentAssetId)) | |
115 | 115 | then throw("Accept SIGN token only") | |
116 | 116 | else { | |
117 | 117 | let currentSIGNPrice = getIntegerValue(storageVerifier, ("certification_fee_" + toBase58String(value(paymentAssetId)))) | |
118 | 118 | if (true) | |
119 | - | then throw(("Uy! " + toString( | |
119 | + | then throw(("Uy! " + toString((amount * 100000000)))) | |
120 | 120 | else { | |
121 | - | let numCredit = (currentSIGNPrice / amount) | |
121 | + | let numCredit = (currentSIGNPrice / (amount * 100000000)) | |
122 | 122 | if ((0 >= numCredit)) | |
123 | 123 | then throw("Not enough for at least 1 credit") | |
124 | 124 | else [IntegerEntry(("credits_" + toBase58String(acceptedToken)), numCredit), ScriptTransfer(addressFromStringValue(signDapp), amount, payment.assetId)] | |
125 | 125 | } | |
126 | 126 | } | |
127 | 127 | } | |
128 | 128 | ||
129 | 129 | ||
130 | 130 | ||
131 | 131 | @Callable(invoke) | |
132 | 132 | func fileCertification (hash,title,uuid,data,signerPubKey) = { | |
133 | 133 | let id = value(invoke.transactionId) | |
134 | 134 | let entryExist = checkEntry(hash, uuid) | |
135 | 135 | let uuidExist = checkUUID(uuid) | |
136 | 136 | let callerAddress = toBase58String(invoke.caller.bytes) | |
137 | 137 | if ((entryExist != "NONE")) | |
138 | 138 | then throw("This entry already exist") | |
139 | 139 | else if ((uuidExist != "NONE")) | |
140 | 140 | then throw("This uuid already exist") | |
141 | 141 | else if ((size(uuid) != 36)) | |
142 | 142 | then throw("Uuid should be 36 characters.") | |
143 | 143 | else if ((size(hash) != 64)) | |
144 | 144 | then throw("Hash should be 64 characters.") | |
145 | 145 | else if ((size(title) > 150)) | |
146 | 146 | then throw("Title is too long, 150 characters max.") | |
147 | 147 | else { | |
148 | 148 | let payment = value(invoke.payments[0]) | |
149 | 149 | let amount = value(payment.amount) | |
150 | 150 | let paymentAssetId = if (isDefined(payment.assetId)) | |
151 | 151 | then value(payment.assetId) | |
152 | 152 | else throw("Waves is not accepted as payment") | |
153 | 153 | let currentPrice = getIntegerValue(this, ("certification_fee_" + toBase58String(value(paymentAssetId)))) | |
154 | 154 | let dappCredits = getIntegerByKey(("credits_" + toBase58String(acceptedToken))) | |
155 | 155 | if ((0 >= dappCredits)) | |
156 | 156 | then throw("Not enough credit on the dapp, please refill") | |
157 | 157 | else if ((acceptedToken != paymentAssetId)) | |
158 | 158 | then throw("This token is not accepted at the moment") | |
159 | 159 | else if ((amount != currentPrice)) | |
160 | 160 | then throw("The price is wrong") | |
161 | 161 | else [StringEntry(uuid, toBase58String(id)), StringEntry((hash + uuid), toBase58String(id)), StringEntry((title + uuid), toBase58String(id)), StringEntry(((("data_fc_" + toBase58String(id)) + "_") + callerAddress), data), IntegerEntry(("credits_" + toBase58String(acceptedToken)), (dappCredits - 1)), ScriptTransfer(addressFromStringValue(bank), amount, payment.assetId)] | |
162 | 162 | } | |
163 | 163 | } | |
164 | 164 | ||
165 | 165 | ||
166 | 166 | ||
167 | 167 | @Callable(invoke) | |
168 | 168 | func revokeCertification (certificationId,signerPubKey) = { | |
169 | 169 | let id = value(invoke.transactionId) | |
170 | 170 | let callerAddress = toBase58String(invoke.caller.bytes) | |
171 | 171 | let entryExist = match getString(this, ((("data_fc_" + certificationId) + "_") + callerAddress)) { | |
172 | 172 | case a: String => | |
173 | 173 | a | |
174 | 174 | case _ => | |
175 | 175 | "NONE" | |
176 | 176 | } | |
177 | 177 | let isRevoked = match getString(this, ("STATUS_FC_" + certificationId)) { | |
178 | 178 | case a: String => | |
179 | 179 | a | |
180 | 180 | case _ => | |
181 | 181 | "NONE" | |
182 | 182 | } | |
183 | 183 | let newJson = (((dropRight(entryExist, 1) + ",\"status\":\"REVOKED_") + toBase58String(id)) + "\"}") | |
184 | 184 | if ((isRevoked != "NONE")) | |
185 | 185 | then throw("This certification have already been revoked.") | |
186 | 186 | else if ((entryExist == "NONE")) | |
187 | 187 | then throw("You cannot change the status of this certification.") | |
188 | 188 | else { | |
189 | 189 | let payment = value(invoke.payments[0]) | |
190 | 190 | let amount = value(payment.amount) | |
191 | 191 | let paymentAssetId = if (isDefined(payment.assetId)) | |
192 | 192 | then value(payment.assetId) | |
193 | 193 | else throw("Waves is not accepted as payment") | |
194 | 194 | let currentPrice = getIntegerValue(this, ("certification_fee_" + toBase58String(value(paymentAssetId)))) | |
195 | 195 | let dappCredits = getIntegerValue(this, ("credits_" + toBase58String(acceptedToken))) | |
196 | 196 | if ((0 >= dappCredits)) | |
197 | 197 | then throw("Not enough credit on the dapp, please refill") | |
198 | 198 | else if ((acceptedToken != paymentAssetId)) | |
199 | 199 | then throw("This token is not accepted at the moment") | |
200 | 200 | else if ((amount != currentPrice)) | |
201 | 201 | then throw("The price is wrong") | |
202 | 202 | else [StringEntry(("STATUS_FC_" + certificationId), ("REVOKED_" + toBase58String(id))), StringEntry(((("data_fc_" + certificationId) + "_") + callerAddress), newJson), IntegerEntry(("credits_" + toBase58String(acceptedToken)), (dappCredits - 1)), ScriptTransfer(addressFromStringValue(bank), amount, payment.assetId)] | |
203 | 203 | } | |
204 | 204 | } | |
205 | 205 | ||
206 | 206 | ||
207 | 207 | ||
208 | 208 | @Callable(i) | |
209 | 209 | func deleteEntry (entry) = { | |
210 | 210 | let caller = toString(addressFromPublicKey(i.callerPublicKey)) | |
211 | 211 | if ((caller == signAdmin)) | |
212 | 212 | then [DeleteEntry(entry)] | |
213 | 213 | else throw("no") | |
214 | 214 | } | |
215 | 215 | ||
216 | 216 |
github/deemru/w8io/026f985 31.06 ms ◑