tx · 4yF8bE6CetRyZSLWkwneD7EetbHSwoTwc22TqPPNcN8m

3N5BB6iE58rujeTEkymeLNcdsYF4f6iKoxr:  -0.01400000 Waves

2022.04.15 17:36 [2009796] smart account 3N5BB6iE58rujeTEkymeLNcdsYF4f6iKoxr > SELF 0.00000000 Waves

{ "type": 13, "id": "4yF8bE6CetRyZSLWkwneD7EetbHSwoTwc22TqPPNcN8m", "fee": 1400000, "feeAssetId": null, "timestamp": 1650033505630, "version": 1, "sender": "3N5BB6iE58rujeTEkymeLNcdsYF4f6iKoxr", "senderPublicKey": "EtZZHS4uqNXY5WPneZ8jY2aA95peXwthJVLzAMxMp379", "proofs": [ "23QwYMAW6ffEQ5XpwAkfkrgYjGThA2d8DQXvvJ3xuuTtcvYKcqPdVn4mrkbU4GDzMFo46eq8pLfsKwwXL4Ynhykz" ], "script": "base64:AAIFAAAAAAAAAFkIAhIECgIIGBIFCgMICAgSAwoBCBIDCgEIEgMKAQgSBAoCCAgSBAoCCAgSBAoCCAgSAwoBCBIFCgMICAQSBAoCCAgSBAoCCAQSAwoBGBIDCgEIEgASAwoBCAAAACUAAAAAA1NFUAIAAAACX18AAAAABUVNUFRZAgAAAAAAAAAADnN0YXR1c1ZlcmlmaWVkAAAAAAAAAAACAAAAABBzdGF0dXNVbnZlcmlmaWVkAAAAAAAAAAAAAAAAABZsYWJlbENvbW11bml0eVZlcmlmaWVkAgAAABJDT01NVU5JVFlfVkVSSUZJRUQAAAAADGxhYmVsUG9vbHNMcAIAAAAIUE9PTFNfTFAAAAAADWRlZmF1bHRMYWJlbHMJAARMAAAAAgUAAAAWbGFiZWxDb21tdW5pdHlWZXJpZmllZAkABEwAAAACBQAAAAxsYWJlbFBvb2xzTHAFAAAAA25pbAEAAAAHdGhyb3dQRAAAAAAJAAACAAAAAQIAAAARUGVybWlzc2lvbiBkZW5pZWQBAAAADHRocm93Tm9Bc3NldAAAAAAJAAACAAAAAQIAAAAUQXNzZXQgZG9lc24ndCBleGlzdHMBAAA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3QgcGVuZGluZyBtYW5hZ2VyAwkAAAAAAAACBQAAAAdjaGVja1BNBQAAAAdjaGVja1BNCQAETAAAAAIJAQAAAAtTdHJpbmdFbnRyeQAAAAIJAQAAABNrZXlNYW5hZ2VyUHVibGljS2V5AAAAAAkAAlgAAAABCQEAAAAFdmFsdWUAAAABBQAAAAJwbQkABEwAAAACCQEAAAALRGVsZXRlRW50cnkAAAABCQEAAAAaa2V5UGVuZGluZ01hbmFnZXJQdWJsaWNLZXkAAAAABQAAAANuaWwJAAACAAAAAQIAAAAkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuCQAAAgAAAAECAAAAJFN0cmljdCB2YWx1ZSBpcyBub3QgZXF1YWwgdG8gaXRzZWxmLgAAAAFpAQAAABJpc1ZlcmlmaWVkUkVBRE9OTFkAAAABAAAAB2Fzc2V0SWQJAAUUAAAAAgUAAAADbmlsCQEAAAAKaXNWZXJpZmllZAAAAAEFAAAAB2Fzc2V0SWQAAAABAAAAAnR4AQAAAAZ2ZXJpZnkAAAAABAAAAA90YXJnZXRQdWJsaWNLZXkEAAAAByRtYXRjaDAJAQAAABZtYW5hZ2VyUHVibGljS2V5T3JVbml0AAAAAAMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAKQnl0ZVZlY3RvcgQAAAACcGsFAAAAByRtYXRjaDAFAAAAAnBrAwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAARVbml0CAUAAAACdHgAAAAPc2VuZGVyUHVibGljS2V5CQAAAgAAAAECAAAAC01hdGNoIGVycm9yCQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAAUAAAAPdGFyZ2V0UHVibGljS2V5s43vYw==", "chainId": 84, "height": 2009796, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: AhcPUACPcS4xWbNT7HfAtBbaYtycEizqajqp1gUg6BKd Next: 9B2mSCgSyfoMx7tRKhXxb4dnDJwzSTznqes1aUkbQkKi Diff:
OldNewDifferences
328328
329329
330330 @Callable(i)
331-func createOrUpdate (assetId,ticker,logo,verified) = {
331+func createOrUpdate (assetId,logo,verified) = {
332332 let checkCaller = mustAdmin(i)
333333 if ((checkCaller == checkCaller))
334334 then {
341341 let setLogoActions = if ((logo == ""))
342342 then nil
343343 else [StringEntry(keyLogo(assetId), logo)]
344- $Tuple2(((([BooleanEntry(keyCreated(assetId), true)] ++ updateTickerActions(assetId, ticker)) ++ setLogoActions) ++ setVerifiedActions(assetId, verified)), isCreatedNow)
344+ $Tuple2((([BooleanEntry(keyCreated(assetId), true)] ++ setLogoActions) ++ setVerifiedActions(assetId, verified)), isCreatedNow)
345345 }
346346 else throw("Strict value is not equal to itself.")
347347 }
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let SEP = "__"
55
66 let EMPTY = ""
77
88 let statusVerified = 2
99
1010 let statusUnverified = 0
1111
1212 let labelCommunityVerified = "COMMUNITY_VERIFIED"
1313
1414 let labelPoolsLp = "POOLS_LP"
1515
1616 let defaultLabels = [labelCommunityVerified, labelPoolsLp]
1717
1818 func throwPD () = throw("Permission denied")
1919
2020
2121 func throwNoAsset () = throw("Asset doesn't exists")
2222
2323
2424 func keyManagerPublicKey () = "%s__managerPublicKey"
2525
2626
2727 func keyPendingManagerPublicKey () = "%s__pendingManagerPublicKey"
2828
2929
3030 func keyAdminPubKeys () = "%s__adminPubKeys"
3131
3232
3333 func keyUserPoolsContract () = "%s__userPoolsContract"
3434
3535
3636 func keyCreated (assetId) = (("created_<" + assetId) + ">")
3737
3838
3939 func keyLogo (assetId) = (("logo_<" + assetId) + ">")
4040
4141
4242 func keyTicker (assetId) = (("ticker_<" + assetId) + ">")
4343
4444
4545 func keyStatus (assetId) = (("status_<" + assetId) + ">")
4646
4747
4848 func keyAssetPoolsNumber (assetId) = makeString(["%s%s", "pools", assetId], SEP)
4949
5050
5151 func keyTickerToAssetId (ticker) = makeString(["%s%s", "ticker2assetId", ticker], SEP)
5252
5353
5454 func keyAssetIdToTicker (assetId) = makeString(["%s%s", "assetId2ticker", assetId], SEP)
5555
5656
5757 func keyAmountAndPriceAssetsToLpAsset (amountAsset,priceAsset) = makeString(["%s%s%s", "amountAndPriceAssetsToLpAsset", amountAsset, priceAsset], SEP)
5858
5959
6060 func keyLpAssetToAmountAndPriceAssets (lpAsset) = makeString(["%s%s", "lpAssetToAmountAndPriceAssets", lpAsset], SEP)
6161
6262
6363 func keyAssetLabels (assetId) = makeString(["%s%s", "labels", assetId], SEP)
6464
6565
6666 func keyLabels () = makeString(["%s", "labels"], SEP)
6767
6868
6969 func isVerified (assetId) = (valueOrElse(getInteger(keyStatus(assetId)), statusUnverified) == statusVerified)
7070
7171
7272 func getLabels () = match getString(keyLabels()) {
7373 case s: String =>
7474 if ((size(s) == 0))
7575 then nil
7676 else split(s, SEP)
7777 case _ =>
7878 nil
7979 }
8080
8181
8282 func getAssetLabels (assetId) = match getString(keyAssetLabels(assetId)) {
8383 case s: String =>
8484 if ((size(s) == 0))
8585 then nil
8686 else split(s, SEP)
8787 case _ =>
8888 nil
8989 }
9090
9191
9292 func managerPublicKeyOrUnit () = match getString(keyManagerPublicKey()) {
9393 case s: String =>
9494 fromBase58String(s)
9595 case _: Unit =>
9696 unit
9797 case _ =>
9898 throw("Match error")
9999 }
100100
101101
102102 func pendingManagerPublicKeyOrUnit () = match getString(keyPendingManagerPublicKey()) {
103103 case s: String =>
104104 fromBase58String(s)
105105 case _: Unit =>
106106 unit
107107 case _ =>
108108 throw("Match error")
109109 }
110110
111111
112112 func mustManager (i) = match managerPublicKeyOrUnit() {
113113 case pk: ByteVector =>
114114 if ((i.callerPublicKey == pk))
115115 then true
116116 else throwPD()
117117 case _: Unit =>
118118 if ((i.caller == this))
119119 then true
120120 else throwPD()
121121 case _ =>
122122 throw("Match error")
123123 }
124124
125125
126126 func mustAdmin (i) = {
127127 let adminPKs = split(valueOrElse(getString(keyAdminPubKeys()), EMPTY), SEP)
128128 if (containsElement(adminPKs, toBase58String(i.callerPublicKey)))
129129 then true
130130 else {
131131 let isManager = mustManager(i)
132132 if ((isManager == isManager))
133133 then true
134134 else throw("Strict value is not equal to itself.")
135135 }
136136 }
137137
138138
139139 func isCreated (assetId) = valueOrElse(getBoolean(keyCreated(assetId)), false)
140140
141141
142142 func verifiedToStatus (verified) = if (verified)
143143 then statusVerified
144144 else statusUnverified
145145
146146
147147 func addLabelActions (assetId,label,throwOnError) = {
148148 let labels = getLabels()
149149 let assetLabels = getAssetLabels(assetId)
150150 let checkLabel = if (containsElement(labels, label))
151151 then true
152152 else throw("Label doesn't exist")
153153 if ((checkLabel == checkLabel))
154154 then {
155155 let newAssetLabels = if (containsElement(assetLabels, label))
156156 then if (throwOnError)
157157 then throw("Label has already been added")
158158 else assetLabels
159159 else (assetLabels :+ label)
160160 [StringEntry(keyAssetLabels(assetId), makeString(newAssetLabels, SEP))]
161161 }
162162 else throw("Strict value is not equal to itself.")
163163 }
164164
165165
166166 func deleteLabelActions (assetId,label,throwOnError) = {
167167 let assetLabels = getAssetLabels(assetId)
168168 let newAssetLabels = if (containsElement(assetLabels, label))
169169 then removeByIndex(assetLabels, value(indexOf(assetLabels, label)))
170170 else if (throwOnError)
171171 then throw("Label wasn't added")
172172 else assetLabels
173173 [StringEntry(keyAssetLabels(assetId), makeString(newAssetLabels, SEP))]
174174 }
175175
176176
177177 func setVerifiedActions (assetId,verified) = {
178178 let labelCommunityVerifiedActions = if (verified)
179179 then addLabelActions(assetId, labelCommunityVerified, false)
180180 else deleteLabelActions(assetId, labelCommunityVerified, false)
181181 ([IntegerEntry(keyStatus(assetId), verifiedToStatus(verified))] ++ labelCommunityVerifiedActions)
182182 }
183183
184184
185185 func updateTickerActions (assetId,ticker) = {
186186 let checkTicker = {
187187 let linkedAssetIdOrUnit = getString(keyTickerToAssetId(ticker))
188188 let tickerIsValid = if ((ticker != ""))
189189 then if ((linkedAssetIdOrUnit == unit))
190190 then true
191191 else (value(linkedAssetIdOrUnit) == assetId)
192192 else false
193193 if (tickerIsValid)
194194 then true
195195 else throw("Invalid ticker")
196196 }
197197 if ((checkTicker == checkTicker))
198198 then [StringEntry(keyAssetIdToTicker(assetId), ticker), StringEntry(keyTickerToAssetId(ticker), assetId)]
199199 else throw("Strict value is not equal to itself.")
200200 }
201201
202202
203203 @Callable(i)
204204 func constructor (userPoolsContract,labels) = {
205205 let checkCaller = mustManager(i)
206206 if ((checkCaller == checkCaller))
207207 then {
208208 let checksAddress = valueOrErrorMessage(addressFromString(userPoolsContract), "Invalid address")
209209 if ((checksAddress == checksAddress))
210210 then [StringEntry(keyUserPoolsContract(), userPoolsContract), StringEntry(keyLabels(), makeString((defaultLabels ++ labels), SEP))]
211211 else throw("Strict value is not equal to itself.")
212212 }
213213 else throw("Strict value is not equal to itself.")
214214 }
215215
216216
217217
218218 @Callable(i)
219219 func addAssetsLink (amountAsset,priceAsset,lpAsset) = {
220220 let checkCaller = mustAdmin(i)
221221 if ((checkCaller == checkCaller))
222222 then [StringEntry(keyAmountAndPriceAssetsToLpAsset(amountAsset, priceAsset), lpAsset), StringEntry(keyLpAssetToAmountAndPriceAssets(lpAsset), makeString([amountAsset, priceAsset], SEP))]
223223 else throw("Strict value is not equal to itself.")
224224 }
225225
226226
227227
228228 @Callable(i)
229229 func increaseAssetPoolsNumber (assetId) = {
230230 let checkCaller = mustAdmin(i)
231231 if ((checkCaller == checkCaller))
232232 then {
233233 let assetPoolsNumberKey = keyAssetPoolsNumber(assetId)
234234 let assetPoolsNumber = valueOrElse(getInteger(assetPoolsNumberKey), 0)
235235 [IntegerEntry(assetPoolsNumberKey, (assetPoolsNumber + 1))]
236236 }
237237 else throw("Strict value is not equal to itself.")
238238 }
239239
240240
241241
242242 @Callable(i)
243243 func createLabel (label) = {
244244 let labels = getLabels()
245245 let checkCaller = mustManager(i)
246246 if ((checkCaller == checkCaller))
247247 then {
248248 let checkLabel = [if (!(contains(label, SEP)))
249249 then true
250250 else throw("Invalid label name"), if (!(containsElement(labels, label)))
251251 then true
252252 else throw("Label exists")]
253253 if ((checkLabel == checkLabel))
254254 then [StringEntry(keyLabels(), makeString((labels :+ label), SEP))]
255255 else throw("Strict value is not equal to itself.")
256256 }
257257 else throw("Strict value is not equal to itself.")
258258 }
259259
260260
261261
262262 @Callable(i)
263263 func dropLabel (label) = {
264264 let labels = getLabels()
265265 let checkCaller = mustManager(i)
266266 if ((checkCaller == checkCaller))
267267 then {
268268 let checkLabel = if (containsElement(labels, label))
269269 then true
270270 else throw("Label doesn't exist")
271271 if ((checkLabel == checkLabel))
272272 then [StringEntry(keyLabels(), makeString(removeByIndex(labels, value(indexOf(labels, label))), SEP))]
273273 else throw("Strict value is not equal to itself.")
274274 }
275275 else throw("Strict value is not equal to itself.")
276276 }
277277
278278
279279
280280 @Callable(i)
281281 func addLabel (assetId,label) = {
282282 let checkCaller = mustAdmin(i)
283283 if ((checkCaller == checkCaller))
284284 then addLabelActions(assetId, label, true)
285285 else throw("Strict value is not equal to itself.")
286286 }
287287
288288
289289
290290 @Callable(i)
291291 func deleteLabel (assetId,label) = {
292292 let checkCaller = mustAdmin(i)
293293 if ((checkCaller == checkCaller))
294294 then deleteLabelActions(assetId, label, true)
295295 else throw("Strict value is not equal to itself.")
296296 }
297297
298298
299299
300300 @Callable(i)
301301 func updateTicker (assetId,ticker) = {
302302 let checkCaller = mustAdmin(i)
303303 if ((checkCaller == checkCaller))
304304 then {
305305 let checkAsset = if (isCreated(assetId))
306306 then true
307307 else throwNoAsset()
308308 if ((checkAsset == checkAsset))
309309 then updateTickerActions(assetId, ticker)
310310 else throw("Strict value is not equal to itself.")
311311 }
312312 else throw("Strict value is not equal to itself.")
313313 }
314314
315315
316316
317317 @Callable(i)
318318 func deleteTicker (assetId) = {
319319 let checkCaller = mustAdmin(i)
320320 if ((checkCaller == checkCaller))
321321 then {
322322 let ticker = valueOrErrorMessage(getString(keyAssetIdToTicker(assetId)), "Invalid asset")
323323 [DeleteEntry(keyAssetIdToTicker(assetId)), DeleteEntry(keyTickerToAssetId(ticker))]
324324 }
325325 else throw("Strict value is not equal to itself.")
326326 }
327327
328328
329329
330330 @Callable(i)
331-func createOrUpdate (assetId,ticker,logo,verified) = {
331+func createOrUpdate (assetId,logo,verified) = {
332332 let checkCaller = mustAdmin(i)
333333 if ((checkCaller == checkCaller))
334334 then {
335335 let checkAssetId = valueOrErrorMessage(assetInfo(fromBase58String(assetId)), "Invalid asset ID")
336336 if ((checkAssetId == checkAssetId))
337337 then {
338338 let isCreatedNow = !(isCreated(assetId))
339339 if ((isCreatedNow == isCreatedNow))
340340 then {
341341 let setLogoActions = if ((logo == ""))
342342 then nil
343343 else [StringEntry(keyLogo(assetId), logo)]
344- $Tuple2(((([BooleanEntry(keyCreated(assetId), true)] ++ updateTickerActions(assetId, ticker)) ++ setLogoActions) ++ setVerifiedActions(assetId, verified)), isCreatedNow)
344+ $Tuple2((([BooleanEntry(keyCreated(assetId), true)] ++ setLogoActions) ++ setVerifiedActions(assetId, verified)), isCreatedNow)
345345 }
346346 else throw("Strict value is not equal to itself.")
347347 }
348348 else throw("Strict value is not equal to itself.")
349349 }
350350 else throw("Strict value is not equal to itself.")
351351 }
352352
353353
354354
355355 @Callable(i)
356356 func setLogo (assetId,logo) = {
357357 let checks = [mustAdmin(i), if (isCreated(assetId))
358358 then true
359359 else throwNoAsset()]
360360 if ((checks == checks))
361361 then [StringEntry(keyLogo(assetId), logo)]
362362 else throw("Strict value is not equal to itself.")
363363 }
364364
365365
366366
367367 @Callable(i)
368368 func setVerified (assetId,verified) = {
369369 let checks = [mustAdmin(i), if (isCreated(assetId))
370370 then true
371371 else throwNoAsset()]
372372 if ((checks == checks))
373373 then {
374374 let priceAssets = match invoke(addressFromStringValue(getStringValue(keyUserPoolsContract())), "priceAssetsREADONLY", nil, nil) {
375375 case assets: List[Any] =>
376376 let checkPriceAssetsSize = if ((size(assets) > 0))
377377 then true
378378 else throw("Invalid price assets")
379379 if ((checkPriceAssetsSize == checkPriceAssetsSize))
380380 then assets
381381 else throw("Strict value is not equal to itself.")
382382 case _ =>
383383 throw("Incorrect invoke result")
384384 }
385385 func cb (acc,item) = {
386386 let priceAssetId = match item {
387387 case s: String =>
388388 s
389389 case _ =>
390390 throw("Invalid price asset")
391391 }
392392 let lpAssetIdOrUnit = getString(keyAmountAndPriceAssetsToLpAsset(assetId, priceAssetId))
393393 let action = if ((lpAssetIdOrUnit == unit))
394394 then nil
395395 else setVerifiedActions(value(lpAssetIdOrUnit), verified)
396396 (acc ++ action)
397397 }
398398
399399 let tokensActions = {
400400 let $l = priceAssets
401401 let $s = size($l)
402402 let $acc0 = setVerifiedActions(assetId, verified)
403403 func $f0_1 ($a,$i) = if (($i >= $s))
404404 then $a
405405 else cb($a, $l[$i])
406406
407407 func $f0_2 ($a,$i) = if (($i >= $s))
408408 then $a
409409 else throw("List size exceeds 10")
410410
411411 $f0_2($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($f0_1($acc0, 0), 1), 2), 3), 4), 5), 6), 7), 8), 9), 10)
412412 }
413413 $Tuple2(tokensActions, unit)
414414 }
415415 else throw("Strict value is not equal to itself.")
416416 }
417417
418418
419419
420420 @Callable(i)
421421 func setAdmins (adminPubKeys) = {
422422 let checkCaller = mustManager(i)
423423 if ((checkCaller == checkCaller))
424424 then [StringEntry(keyAdminPubKeys(), makeString(adminPubKeys, SEP))]
425425 else throw("Strict value is not equal to itself.")
426426 }
427427
428428
429429
430430 @Callable(i)
431431 func setManager (pendingManagerPublicKey) = {
432432 let checkCaller = mustManager(i)
433433 if ((checkCaller == checkCaller))
434434 then {
435435 let checkManagerPublicKey = fromBase58String(pendingManagerPublicKey)
436436 if ((checkManagerPublicKey == checkManagerPublicKey))
437437 then [StringEntry(keyPendingManagerPublicKey(), pendingManagerPublicKey)]
438438 else throw("Strict value is not equal to itself.")
439439 }
440440 else throw("Strict value is not equal to itself.")
441441 }
442442
443443
444444
445445 @Callable(i)
446446 func confirmManager () = {
447447 let pm = pendingManagerPublicKeyOrUnit()
448448 let hasPM = if (isDefined(pm))
449449 then true
450450 else throw("No pending manager")
451451 if ((hasPM == hasPM))
452452 then {
453453 let checkPM = if ((i.callerPublicKey == value(pm)))
454454 then true
455455 else throw("You are not pending manager")
456456 if ((checkPM == checkPM))
457457 then [StringEntry(keyManagerPublicKey(), toBase58String(value(pm))), DeleteEntry(keyPendingManagerPublicKey())]
458458 else throw("Strict value is not equal to itself.")
459459 }
460460 else throw("Strict value is not equal to itself.")
461461 }
462462
463463
464464
465465 @Callable(i)
466466 func isVerifiedREADONLY (assetId) = $Tuple2(nil, isVerified(assetId))
467467
468468
469469 @Verifier(tx)
470470 func verify () = {
471471 let targetPublicKey = match managerPublicKeyOrUnit() {
472472 case pk: ByteVector =>
473473 pk
474474 case _: Unit =>
475475 tx.senderPublicKey
476476 case _ =>
477477 throw("Match error")
478478 }
479479 sigVerify(tx.bodyBytes, tx.proofs[0], targetPublicKey)
480480 }
481481

github/deemru/w8io/026f985 
81.00 ms