tx · 7WY1qii5a9eQQXEuTa1yQ8hQhZMcLb6rZfyub8U4BXY4
3MyY8HWSxxH8SLxnBHgYZQh26FVgybkTTp9: -0.00200000 Waves
2022.07.29 14:04 [2161024] smart account 3MyY8HWSxxH8SLxnBHgYZQh26FVgybkTTp9 > SELF 0.00000000 Waves
{
"type": 13,
"id": "7WY1qii5a9eQQXEuTa1yQ8hQhZMcLb6rZfyub8U4BXY4",
"fee": 200000,
"feeAssetId": null,
"timestamp": 1659092678239,
"version": 2,
"chainId": 84,
"sender": "3MyY8HWSxxH8SLxnBHgYZQh26FVgybkTTp9",
"senderPublicKey": "69whdb3wz2NxWkDP633fGFWMnqmhZSDPJ5ThCu3x47jU",
"proofs": [
"2c8bKYzJ9iJu4GD6TjcRovQ9WwGgbX3EJh3x2qQ9xUhX1Nbgf3snpNUJTJ4RuScBnWHiCMZxFsq8aF9MMjb8cjc9"
],
"script": "base64:AAIFAAAAAAAAAAQIAhIAAAAACgEAAAAMdHJ5R2V0U3RyaW5nAAAAAQAAAANrZXkEAAAAA3ZhbAQAAAAHJG1hdGNoMAkABB0AAAACBQAAAAR0aGlzBQAAAANrZXkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAABlN0cmluZwQAAAABYgUAAAAHJG1hdGNoMAUAAAABYgIAAAAABQAAAAN2YWwBAAAADXRyeUdldEludGVnZXIAAAABAAAAA2tleQQAAAADdmFsBAAAAAckbWF0Y2gwCQAEGgAAAAIFAAAABHRoaXMFAAAAA2tleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAADSW50BAAAAAFiBQAAAAckbWF0Y2gwBQAAAAFiAAAAAAAAAAAABQAAAAN2YWwBAAAAB2lzT3duZXIAAAABAAAAB2FkZHJlc3MJAAAAAAAAAgUAAAAHYWRkcmVzcwUAAAAEdGhpcwAAAAAbQ09VUlNfQ0VSVElGSUNBVEVfVElMRV9URVhUAgAAAA9ORlQgQ2VydGlmaWNhdGUAAAAAJ0NPVVJTX0NFUlRJRklDQVRF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AEJQAAAAEFAAAAB2FkZHJlc3MDCQEAAAACIT0AAAACCQEAAAAMdHJ5R2V0U3RyaW5nAAAAAQUAAAADa2V5AgAAAAAGBwAAAAEAAAABaQEAAAAIaXNzdWVORlQAAAAABAAAAANrZXkJAAEsAAAAAgIAAAAIaGlzdG9yeV8JAAQlAAAAAQgFAAAAAWkAAAAGY2FsbGVyAwkAAAAAAAACCQEAAAAMdHJ5R2V0U3RyaW5nAAAAAQUAAAADa2V5AgAAAAAJAAUUAAAAAgkABEwAAAACCQEAAAAMQm9vbGVhbkVudHJ5AAAAAgkAASwAAAACAgAAAAhoaXN0b3J5XwkABCUAAAABCAUAAAABaQAAAAZjYWxsZXIGCQAETAAAAAIJAARCAAAABQUAAAAbQ09VUlNfQ0VSVElGSUNBVEVfVElMRV9URVhUCQEAAAAeZ2V0Q291cnNDZXJ0aWZpY2F0ZURlc2NyaXB0aW9uAAAAAQkABCUAAAABCAUAAAABaQAAAAZjYWxsZXIAAAAAAAAAAAEAAAAAAAAAAAAHBQAAAANuaWwFAAAABHVuaXQJAAACAAAAAQUAAAArQ09VUlNfRVJST1JfQ0VSVElGSUNBVEVfQUxSRUFEWV9JU1NVRURfVEVYVAAAAAD3pUJT",
"height": 2161024,
"applicationStatus": "succeeded",
"spentComplexity": 0
}
View: original | compacted
Prev: DLsfAkjiWUtxPCqWLaHeq4xZ7sWhcrtgQLGmzm7j3Bhh
Next: 8NKSvYajriK4GDqJkByjx7XCvLyA3w7UoSzrtoZEwmLf
Diff:
Old | New | | Differences |
---|
43 | 43 | | |
---|
44 | 44 | | let m = "A certificate has already been issued at your address" |
---|
45 | 45 | | |
---|
46 | | - | func n (h) = { |
---|
| 46 | + | func n (h) = [BooleanEntry(("history_" + toString(h)), true)] |
---|
| 47 | + | |
---|
| 48 | + | |
---|
| 49 | + | func o (h) = { |
---|
47 | 50 | | let b = ("history_" + toString(h)) |
---|
48 | 51 | | if ((a(b) != "")) |
---|
49 | | - | then throw(m) |
---|
50 | | - | else [BooleanEntry(b, true)] |
---|
| 52 | + | then true |
---|
| 53 | + | else false |
---|
51 | 54 | | } |
---|
52 | 55 | | |
---|
53 | 56 | | |
---|
54 | | - | @Callable(o) |
---|
55 | | - | func issueNFT (h) = $Tuple2([Issue(i, l(h), 1, 0, false)], unit) |
---|
| 57 | + | @Callable(p) |
---|
| 58 | + | func issueNFT () = { |
---|
| 59 | + | let b = ("history_" + toString(p.caller)) |
---|
| 60 | + | if ((a(b) == "")) |
---|
| 61 | + | then $Tuple2([BooleanEntry(("history_" + toString(p.caller)), true), Issue(i, l(toString(p.caller)), 1, 0, false)], unit) |
---|
| 62 | + | else throw(m) |
---|
| 63 | + | } |
---|
56 | 64 | | |
---|
57 | 65 | | |
---|
Full:
Old | New | | Differences |
---|
1 | 1 | | {-# STDLIB_VERSION 5 #-} |
---|
2 | 2 | | {-# SCRIPT_TYPE ACCOUNT #-} |
---|
3 | 3 | | {-# CONTENT_TYPE DAPP #-} |
---|
4 | 4 | | func a (b) = { |
---|
5 | 5 | | let c = { |
---|
6 | 6 | | let d = getString(this, b) |
---|
7 | 7 | | if ($isInstanceOf(d, "String")) |
---|
8 | 8 | | then { |
---|
9 | 9 | | let e = d |
---|
10 | 10 | | e |
---|
11 | 11 | | } |
---|
12 | 12 | | else "" |
---|
13 | 13 | | } |
---|
14 | 14 | | c |
---|
15 | 15 | | } |
---|
16 | 16 | | |
---|
17 | 17 | | |
---|
18 | 18 | | func f (b) = { |
---|
19 | 19 | | let c = { |
---|
20 | 20 | | let d = getInteger(this, b) |
---|
21 | 21 | | if ($isInstanceOf(d, "Int")) |
---|
22 | 22 | | then { |
---|
23 | 23 | | let e = d |
---|
24 | 24 | | e |
---|
25 | 25 | | } |
---|
26 | 26 | | else 0 |
---|
27 | 27 | | } |
---|
28 | 28 | | c |
---|
29 | 29 | | } |
---|
30 | 30 | | |
---|
31 | 31 | | |
---|
32 | 32 | | func g (h) = (h == this) |
---|
33 | 33 | | |
---|
34 | 34 | | |
---|
35 | 35 | | let i = "NFT Certificate" |
---|
36 | 36 | | |
---|
37 | 37 | | let j = "This NFT certificate certifies the completion of the course for a user with a wallet address of " |
---|
38 | 38 | | |
---|
39 | 39 | | let k = ". The user has gained in-depth knowledge in understanding the operation of the blockchain, interacting with the exchange, and successfully passed the course exams." |
---|
40 | 40 | | |
---|
41 | 41 | | func l (h) = ((j + h) + k) |
---|
42 | 42 | | |
---|
43 | 43 | | |
---|
44 | 44 | | let m = "A certificate has already been issued at your address" |
---|
45 | 45 | | |
---|
46 | | - | func n (h) = { |
---|
| 46 | + | func n (h) = [BooleanEntry(("history_" + toString(h)), true)] |
---|
| 47 | + | |
---|
| 48 | + | |
---|
| 49 | + | func o (h) = { |
---|
47 | 50 | | let b = ("history_" + toString(h)) |
---|
48 | 51 | | if ((a(b) != "")) |
---|
49 | | - | then throw(m) |
---|
50 | | - | else [BooleanEntry(b, true)] |
---|
| 52 | + | then true |
---|
| 53 | + | else false |
---|
51 | 54 | | } |
---|
52 | 55 | | |
---|
53 | 56 | | |
---|
54 | | - | @Callable(o) |
---|
55 | | - | func issueNFT (h) = $Tuple2([Issue(i, l(h), 1, 0, false)], unit) |
---|
| 57 | + | @Callable(p) |
---|
| 58 | + | func issueNFT () = { |
---|
| 59 | + | let b = ("history_" + toString(p.caller)) |
---|
| 60 | + | if ((a(b) == "")) |
---|
| 61 | + | then $Tuple2([BooleanEntry(("history_" + toString(p.caller)), true), Issue(i, l(toString(p.caller)), 1, 0, false)], unit) |
---|
| 62 | + | else throw(m) |
---|
| 63 | + | } |
---|
56 | 64 | | |
---|
57 | 65 | | |
---|