tx · 9GYPAyfhqiYimH47YRCuTtH4YP9W1tuJsBGd9iX3mfeq
3N5NY2v5wdKQJbCvQA5o5hSihn7t7wYZ496: -0.01000000 Waves
2025.01.08 16:33 [3450261] smart account 3N5NY2v5wdKQJbCvQA5o5hSihn7t7wYZ496 > SELF 0.00000000 Waves
{
"type": 13,
"id": "9GYPAyfhqiYimH47YRCuTtH4YP9W1tuJsBGd9iX3mfeq",
"fee": 1000000,
"feeAssetId": null,
"timestamp": 1736343226237,
"version": 2,
"chainId": 84,
"sender": "3N5NY2v5wdKQJbCvQA5o5hSihn7t7wYZ496",
"senderPublicKey": "8Ti3dhEToApephiZ47QJeuQX3UYifveNLPQjNstsLho9",
"proofs": [
"2ChfcG3Nme2NqQDMDbHDPfB1QpGFoZL9MzSqojb2FUgVb15F2V9gRLyh4SEWrY4gdRdvkoQsvQRguS943qdfpFwT"
],
"script": "base64:AAIFAAAAAAAAABQIAhIFCgMICAgSAwoBCBIECgIICAAAAAMAAAAADGFkbWluQWRkcmVzcwkBAAAAB0FkZHJlc3MAAAABAQAAABoBVAqh3jB68WUdF1MeXFctJAWzG0XQgRHu1wAAAAALZEFwcEFkZHJlc3MJAQAAAAdBZGRyZXNzAAAAAQEAAAAaAVSNFVN42dVClMcMW1BboH6NujWeWSoZV/ABAAAADXNlYXJjaEZvclVzZXIAAAABAAAAB2FkZHJlc3MEAAAABHVzZXIEAAAAByRtYXRjaDAJAAQiAAAAAQUAAAAHYWRkcmVzcwMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAGU3RyaW5nBAAAAAFzBQAAAAckbWF0Y2gwBQAAAAFzAgAAAAdObyBVc2VyBQAAAAR1c2VyAAAAAwAAAAFpAQAAAA9yZWdpc3RlckFjY291bnQAAAADAAAAB2FkZHJlc3MAAAAEcm9sZQAAAARuYW1lBAAAAAZjYWxsZXIIBQAAAAFpAAAAD2NhbGxlclB1YmxpY0tleQQAAAAEdXNlcgkBAAAADXNlYXJjaEZvclVzZXIAAAABCQACW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lVGFzawkAA/wAAAAEBQAAAAtkQXBwQWRkcmVzcwIAAAAIU2F2ZURhdGEFAAAACnBhcmFtZXRlcnMFAAAAA25pbAMJAQAAAAIhPQAAAAIFAAAACmludm9rZVRhc2sFAAAACmludm9rZVRhc2sJAAACAAAAAQIAAAAkU3RyaWN0IHZhbHVlIGlzIG5vdCBlcXVhbCB0byBpdHNlbGYuBQAAAANuaWwAAAAA3mAeMQ==",
"height": 3450261,
"applicationStatus": "succeeded",
"spentComplexity": 0
}
View: original | compacted
Prev: C6R1q8tzqP3tQXxuDn6b9cWyGBzoq2oxbE6KjeQ3ToqL
Next: none
Diff:
Old | New | | Differences |
---|
20 | 20 | | |
---|
21 | 21 | | |
---|
22 | 22 | | @Callable(h) |
---|
23 | | - | func registerAccount (d,i,j) = if ((h.caller != a)) |
---|
24 | | - | then throw("Only the admin can register accounts") |
---|
25 | | - | else [StringEntry(d, i), StringEntry((d + "_name"), j)] |
---|
| 23 | + | func registerAccount (d,i,j) = { |
---|
| 24 | + | let k = h.callerPublicKey |
---|
| 25 | + | let e = c(toBase58String(k)) |
---|
| 26 | + | if ((e != "Admin")) |
---|
| 27 | + | then throw("Only the admin can delete accounts") |
---|
| 28 | + | else [StringEntry(d, i), StringEntry((d + "_name"), j)] |
---|
| 29 | + | } |
---|
26 | 30 | | |
---|
27 | 31 | | |
---|
28 | 32 | | |
---|
Full:
Old | New | | Differences |
---|
1 | 1 | | {-# STDLIB_VERSION 5 #-} |
---|
2 | 2 | | {-# SCRIPT_TYPE ACCOUNT #-} |
---|
3 | 3 | | {-# CONTENT_TYPE DAPP #-} |
---|
4 | 4 | | let a = Address(base58'3MptJSctbAkp5fddvpQmWYjjKrSoim6dL38') |
---|
5 | 5 | | |
---|
6 | 6 | | let b = Address(base58'3N2n4bjG8CjdKiwLPyp3hBM4MDJ3XwMZR5h') |
---|
7 | 7 | | |
---|
8 | 8 | | func c (d) = { |
---|
9 | 9 | | let e = { |
---|
10 | 10 | | let f = getString(d) |
---|
11 | 11 | | if ($isInstanceOf(f, "String")) |
---|
12 | 12 | | then { |
---|
13 | 13 | | let g = f |
---|
14 | 14 | | g |
---|
15 | 15 | | } |
---|
16 | 16 | | else "No User" |
---|
17 | 17 | | } |
---|
18 | 18 | | e |
---|
19 | 19 | | } |
---|
20 | 20 | | |
---|
21 | 21 | | |
---|
22 | 22 | | @Callable(h) |
---|
23 | | - | func registerAccount (d,i,j) = if ((h.caller != a)) |
---|
24 | | - | then throw("Only the admin can register accounts") |
---|
25 | | - | else [StringEntry(d, i), StringEntry((d + "_name"), j)] |
---|
| 23 | + | func registerAccount (d,i,j) = { |
---|
| 24 | + | let k = h.callerPublicKey |
---|
| 25 | + | let e = c(toBase58String(k)) |
---|
| 26 | + | if ((e != "Admin")) |
---|
| 27 | + | then throw("Only the admin can delete accounts") |
---|
| 28 | + | else [StringEntry(d, i), StringEntry((d + "_name"), j)] |
---|
| 29 | + | } |
---|
26 | 30 | | |
---|
27 | 31 | | |
---|
28 | 32 | | |
---|
29 | 33 | | @Callable(h) |
---|
30 | 34 | | func deleteAccount (d) = { |
---|
31 | 35 | | let k = h.callerPublicKey |
---|
32 | 36 | | let e = c(toBase58String(k)) |
---|
33 | 37 | | if ((e != "Admin")) |
---|
34 | 38 | | then throw("Only the admin can delete accounts") |
---|
35 | 39 | | else [DeleteEntry(d), DeleteEntry((d + "_name"))] |
---|
36 | 40 | | } |
---|
37 | 41 | | |
---|
38 | 42 | | |
---|
39 | 43 | | |
---|
40 | 44 | | @Callable(h) |
---|
41 | 45 | | func saveData (l,m) = { |
---|
42 | 46 | | let k = h.callerPublicKey |
---|
43 | 47 | | let e = c(toBase58String(k)) |
---|
44 | 48 | | if ((e == "No User")) |
---|
45 | 49 | | then throw("User not eligible") |
---|
46 | 50 | | else { |
---|
47 | 51 | | let n = [l, m] |
---|
48 | 52 | | let o = invoke(b, "SaveData", n, nil) |
---|
49 | 53 | | if ((o != o)) |
---|
50 | 54 | | then throw("Strict value is not equal to itself.") |
---|
51 | 55 | | else nil |
---|
52 | 56 | | } |
---|
53 | 57 | | } |
---|
54 | 58 | | |
---|
55 | 59 | | |
---|