tx · B8Gj92TgwGhSECBnJzaCsS9XHjxhPsyAs3vvZPUNQXyf
3Mqnv1LY2i4hshvHyccL5GEAVbVPRerPjKM: -0.01000000 Waves
2022.11.24 19:07 [2331402] smart account 3Mqnv1LY2i4hshvHyccL5GEAVbVPRerPjKM > SELF 0.00000000 Waves
{
"type": 13,
"id": "B8Gj92TgwGhSECBnJzaCsS9XHjxhPsyAs3vvZPUNQXyf",
"fee": 1000000,
"feeAssetId": null,
"timestamp": 1669306051499,
"version": 2,
"chainId": 84,
"sender": "3Mqnv1LY2i4hshvHyccL5GEAVbVPRerPjKM",
"senderPublicKey": "FB5Eb3jaoFSDQEnfsjbmvMoP3Cc8ejvBySpsfYWC1vBg",
"proofs": [
"tMHsK1NLFgPEVNGJf9cjZCdRbe4UzWgQVfPmA3mdMCfVbn4TKktrqK4iQ4qdJ8fjtGC6XqqtdmgH2JpRoRerz7t"
],
"script": "base64:AAIFAAAAAAAAAAgIAhIECgIICAAAAAEBAAAAB2dldERhdGEAAAACAAAAA2FkcgAAAANrZXkEAAAABGRhdGEEAAAAByRtYXRjaDAJAAQdAAAAAgUAAAADYWRyBQAAAANrZXkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAABlN0cmluZwQAAAABYQUAAAAHJG1hdGNoMAUAAAABYQIAAAAABQAAAARkYXRhAAAAAQAAAAFpAQAAABpzYXZlVmFsdWVPblN1cHBsaWVyQWNjb3VudAAAAAIAAAANZGVsSW5mVGV4dEtleQAAAA9kZWxJbmZUZXh0VmFsdWUEAAAADGVnZ2VyQWRkcmVzcwkAAlgAAAABCAgFAAAAAWkAAAAGY2FsbGVyAAAABWJ5dGVzBAAAAA5lZ2dlclB1YmxpY0tleQkAAlgAAAABCAUAAAABaQAAAA9jYWxsZXJQdWJsaWNLZXkEAAAAEmVnZ2VyUHVibGljS2V5SGFzaAkAAfcAAAABCAUAAAABaQAAAA9jYWxsZXJQdWJsaWNLZXkEAAAAI2VnZ2VyUHVibGljS2V5SGFzaE9uU3VwcGxpZXJBY2NvdW50CQABmwAAAAEJAQAAAAdnZXREYXRhAAAAAgUAAAAEdGhpcwIAAAAUY29ubmVjdGlvbi5FZ2dlci5yZWYJAARMAAAAAgkBAAAAC0JpbmFyeUVudHJ5AAAAAgIAAAAMcHViS2V5Q2FsbGVyBQAAABJlZ2dlclB1YmxpY0tleUhhc2gJAARMAAAAAgkBAAAAC0JpbmFyeUVudHJ5AAAAAgIAAAAOcHViS2V5T25TY3JpcHQFAAAAI2VnZ2VyUHVibGljS2V5SGFzaE9uU3VwcGxpZXJBY2NvdW50BQAAAANuaWwAAAABAAAAAnR4AQAAAAZ2ZXJpZnkAAAAACQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAAgFAAAAAnR4AAAAD3NlbmRlclB1YmxpY0tlecVf2e8=",
"height": 2331402,
"applicationStatus": "succeeded",
"spentComplexity": 0
}
View: original | compacted
Prev: DSPEEaBmRp3foZJUBg7wmUghnzorGqbnWgsGxTt9nmnb
Next: 84XherACDKqJfncrKQ7new1LLDRjdMFDrs92KRRWTMYi
Diff:
Old | New | | Differences |
---|
18 | 18 | | let eggerPublicKey = toBase58String(i.callerPublicKey) |
---|
19 | 19 | | let eggerPublicKeyHash = sha256(i.callerPublicKey) |
---|
20 | 20 | | let eggerPublicKeyHashOnSupplierAccount = toBytes(getData(this, "connection.Egger.ref")) |
---|
21 | | - | if ((eggerPublicKeyHash == eggerPublicKeyHashOnSupplierAccount)) |
---|
22 | | - | then [StringEntry("test1", "test2")] |
---|
23 | | - | else throw("Account hat nicht die nötige Berechtigung für diese Aktion.") |
---|
| 21 | + | [BinaryEntry("pubKeyCaller", eggerPublicKeyHash), BinaryEntry("pubKeyOnScript", eggerPublicKeyHashOnSupplierAccount)] |
---|
24 | 22 | | } |
---|
25 | 23 | | |
---|
26 | 24 | | |
---|
Full:
Old | New | | Differences |
---|
1 | 1 | | {-# STDLIB_VERSION 5 #-} |
---|
2 | 2 | | {-# SCRIPT_TYPE ACCOUNT #-} |
---|
3 | 3 | | {-# CONTENT_TYPE DAPP #-} |
---|
4 | 4 | | func getData (adr,key) = { |
---|
5 | 5 | | let data = match getString(adr, key) { |
---|
6 | 6 | | case a: String => |
---|
7 | 7 | | a |
---|
8 | 8 | | case _ => |
---|
9 | 9 | | "" |
---|
10 | 10 | | } |
---|
11 | 11 | | data |
---|
12 | 12 | | } |
---|
13 | 13 | | |
---|
14 | 14 | | |
---|
15 | 15 | | @Callable(i) |
---|
16 | 16 | | func saveValueOnSupplierAccount (delInfTextKey,delInfTextValue) = { |
---|
17 | 17 | | let eggerAddress = toBase58String(i.caller.bytes) |
---|
18 | 18 | | let eggerPublicKey = toBase58String(i.callerPublicKey) |
---|
19 | 19 | | let eggerPublicKeyHash = sha256(i.callerPublicKey) |
---|
20 | 20 | | let eggerPublicKeyHashOnSupplierAccount = toBytes(getData(this, "connection.Egger.ref")) |
---|
21 | | - | if ((eggerPublicKeyHash == eggerPublicKeyHashOnSupplierAccount)) |
---|
22 | | - | then [StringEntry("test1", "test2")] |
---|
23 | | - | else throw("Account hat nicht die nötige Berechtigung für diese Aktion.") |
---|
| 21 | + | [BinaryEntry("pubKeyCaller", eggerPublicKeyHash), BinaryEntry("pubKeyOnScript", eggerPublicKeyHashOnSupplierAccount)] |
---|
24 | 22 | | } |
---|
25 | 23 | | |
---|
26 | 24 | | |
---|
27 | 25 | | @Verifier(tx) |
---|
28 | 26 | | func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey) |
---|
29 | 27 | | |
---|