tx · D7aJkQb2AQDfQ93LXYkGnmKUis9fb7YKeaW8aJSj7N9x 3MxvJx8XiWkCvZzpusprD9H9kyhcvQTcmX8: -0.01000000 Waves 2023.01.31 21:34 [2429485] smart account 3MxvJx8XiWkCvZzpusprD9H9kyhcvQTcmX8 > SELF 0.00000000 Waves
{ "type": 13, "id": "D7aJkQb2AQDfQ93LXYkGnmKUis9fb7YKeaW8aJSj7N9x", "fee": 1000000, "feeAssetId": null, "timestamp": 1675190108151, "version": 2, "chainId": 84, "sender": "3MxvJx8XiWkCvZzpusprD9H9kyhcvQTcmX8", "senderPublicKey": "48qfJdp84ZnZXHJRQbqYm2peuKvphT6kQf3WSBE46T2t", "proofs": [ "2LkSxvG54Dh46DeUbtkcPGptHYhQFJsXPQjAYSHJtQazgULh5cWLaZ6pqNYpd7c2zTyasvsWW6kDDAoYuWEDLaWt", "gcnnSiYtew6BVhvs3oVqUHGP7FfbXB5v6zwo7S8DZRSkpGf4B7xm6K4kL5JUbL5hkgDe8kQ9F7xAm7tEMrGWaKv" ], "script": "base64:BgIICAISBAoCCAgAAQFpAQlzZXRPcHRpb24CCHZhcmlhYmxlBXZhbHVlBAlhZG1pbkxpc3QEByRtYXRjaDAJAJ0IAgUEdGhpcwIKYWRtaW5fbGlzdAMJAAECBQckbWF0Y2gwAgRVbml0AgV1bnNldAMJAAECBQckbWF0Y2gwAgZTdHJpbmcEAXgFByRtYXRjaDAFAXgJAAIBAgtNYXRjaCBlcnJvcgQQY2FsbGVyQWRkcmVzc1N0cgkApQgBCAUBaQZjYWxsZXIDCQECIT0CBQlhZG1pbkxpc3QCBXVuc2V0BAdpc0FkbWluBAckbWF0Y2gwCQCdCAIFBHRoaXMFEGNhbGxlckFkZHJlc3NTdHIDCQABAgUHJG1hdGNoMAIEVW5pdAIIbm8gYWRtaW4DCQABAgUHJG1hdGNoMAIGU3RyaW5nBAF4BQckbWF0Y2gwBQF4CQACAQILTWF0Y2ggZXJyb3IDCQECIT0CBQdpc0FkbWluAghubyBhZG1pbgkAlAoCCQDMCAIJAQtTdHJpbmdFbnRyeQIFCHZhcmlhYmxlBQV2YWx1ZQUDbmlsBQR1bml0CQACAQkArAICAg9Zb3Ugbm90IGFkbWluOiAFCWFkbWluTGlzdAkAAgECEFVuc2V0IGFkbWluIGxpc3QBAnR4AQZ2ZXJpZnkABAckbWF0Y2gwBQJ0eAkA9AMDCAUCdHgJYm9keUJ5dGVzCQCRAwIIBQJ0eAZwcm9vZnMAAAgFAnR4D3NlbmRlclB1YmxpY0tleY03cRE=", "height": 2429485, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: CWE7PdoUSwzPkcTDHWRTPyLYyCpnHxpQbvh3Qv4bMoZo Next: none Full:
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 6 #-} | |
2 | - | {-# CONTENT_TYPE EXPRESSION #-} | |
3 | - | match tx { | |
2 | + | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | + | {-# CONTENT_TYPE DAPP #-} | |
4 | + | ||
5 | + | ||
6 | + | @Callable(i) | |
7 | + | func setOption (variable,value) = { | |
8 | + | let adminList = match getString(this, "admin_list") { | |
9 | + | case _: Unit => | |
10 | + | "unset" | |
11 | + | case x: String => | |
12 | + | x | |
13 | + | case _ => | |
14 | + | throw("Match error") | |
15 | + | } | |
16 | + | let callerAddressStr = toString(i.caller) | |
17 | + | if ((adminList != "unset")) | |
18 | + | then { | |
19 | + | let isAdmin = match getString(this, callerAddressStr) { | |
20 | + | case _: Unit => | |
21 | + | "no admin" | |
22 | + | case x: String => | |
23 | + | x | |
24 | + | case _ => | |
25 | + | throw("Match error") | |
26 | + | } | |
27 | + | if ((isAdmin != "no admin")) | |
28 | + | then $Tuple2([StringEntry(variable, value)], unit) | |
29 | + | else throw(("You not admin: " + adminList)) | |
30 | + | } | |
31 | + | else throw("Unset admin list") | |
32 | + | } | |
33 | + | ||
34 | + | ||
35 | + | @Verifier(tx) | |
36 | + | func verify () = match tx { | |
4 | 37 | case _ => | |
5 | 38 | sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey) | |
6 | 39 | } | |
40 | + |
github/deemru/w8io/169f3d6 22.34 ms ◑