tx · 6JsTkyZfChbBvwTNHCKWUpf3wfoceFNsgRktoUw1itBF
3NBHyQ67TPHySpoiugp35ZBDmy57KGbLiqH: -0.09000000 Waves
2021.03.18 18:46 [1443378] smart account 3NBHyQ67TPHySpoiugp35ZBDmy57KGbLiqH > SELF 0.00000000 Waves
{
"type": 13,
"id": "6JsTkyZfChbBvwTNHCKWUpf3wfoceFNsgRktoUw1itBF",
"fee": 9000000,
"feeAssetId": null,
"timestamp": 1616082425296,
"version": 2,
"chainId": 84,
"sender": "3NBHyQ67TPHySpoiugp35ZBDmy57KGbLiqH",
"senderPublicKey": "BEhKtjrMZynwX3AJB6WJbFrM6UxW9ytKVsn1nRb7pKrX",
"proofs": [
"29jPt46STeqonz2DAkr6VJiMBHNVorozvG95LGUpc4LLbBT1cn58d3vrqzw5pst6f6rWqorU3cbhZhh1HywDPN1d"
],
"script": "base64:AAIEAAAAAAAAAAcIAhIDCgEIAAAAAQEAAAATZ2V0RGF0YUZyb21DdXN0b21lcgAAAAIAAAADa2V5AAAAA2FkcgQAAAAEZGF0YQQAAAAHJG1hdGNoMAkABB0AAAACBQAAAANhZHIFAAAAA2tleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAAGU3RyaW5nBAAAAAFhBQAAAAckbWF0Y2gwBQAAAAFhAgAAAAAFAAAABGRhdGEAAAABAAAAAWkBAAAAC3BlcmZvbU9yZGVyAAAAAQAAAARkYXRlBAAAAA1jYWxsZXJBZGRyZXNzCQEAAAAUYWRkcmVzc0Zyb21QdWJsaWNLZXkAAAABCAUAAAABaQAAAA9jYWxsZXJQdWJsaWNLZXkEAAAABmZpZWxkMQkBAAAAE2dldERhdGFGcm9tQ3VzdG9tZXIAAAACCQABLAAAAAIJAASwAAAAAQgFAAAAAWkAAAAPY2FsbGVyUHVibGljS2V5AgAAACpfT1JERVJTOi9HRVZJU0VESTAxL0hlYWRlci9OYWNocmljaHRlbnR5cF8FAAAADWNhbGxlckFkZHJlc3MDCQAAAAAAAAIFAAAABmZpZWxkMQIAAAAACQAETAAAAAIJAQAAAAtTdHJpbmdFbnRyeQAAAAICAAAAIF8vT1JERVJTMDUvSURPQy9FRElfREM0MC9NRVNUWVBfAgAAAAJzZAUAAAADbmlsCQAAAgAAAAECAAAAC2ZpZWxkIGVtcHR5AAAAAQAAAAJ0eAEAAAAGdmVyaWZ5AAAAAAQAAAAHJG1hdGNoMAUAAAACdHgDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAD0RhdGFUcmFuc2FjdGlvbgYDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAFFNldFNjcmlwdFRyYW5zYWN0aW9uBgZqcjaV",
"height": 1443378,
"applicationStatus": "succeeded",
"spentComplexity": 0
}
View: original | compacted
Prev: FGy7wd38VmrWtboE3o3rAEUzW1DPagF6mV1QdGDxpnRx
Next: DB6ik7aq526FtxFLacoGNRxXiwgj8rrpkMWmAXzdLCLo
Diff:
Old | New | | Differences |
---|
1 | 1 | | {-# STDLIB_VERSION 4 #-} |
---|
2 | 2 | | {-# SCRIPT_TYPE ACCOUNT #-} |
---|
3 | 3 | | {-# CONTENT_TYPE DAPP #-} |
---|
4 | | - | func getstoredData (adr) = { |
---|
5 | | - | let test = match getString(adr, "test") { |
---|
| 4 | + | func getDataFromCustomer (key,adr) = { |
---|
| 5 | + | let data = match getString(adr, key) { |
---|
6 | 6 | | case a: String => |
---|
7 | 7 | | a |
---|
8 | 8 | | case _ => |
---|
9 | 9 | | "" |
---|
10 | 10 | | } |
---|
11 | | - | test |
---|
| 11 | + | data |
---|
12 | 12 | | } |
---|
13 | 13 | | |
---|
14 | 14 | | |
---|
15 | 15 | | @Callable(i) |
---|
16 | | - | func storeData () = { |
---|
17 | | - | let account = base58'3MtE2oCkjx6BLhk6tviDComNZYHnohwczd7' |
---|
18 | | - | let testData = getstoredData(Address(account)) |
---|
19 | | - | if ((testData != "")) |
---|
20 | | - | then [StringEntry("mytest_", testData)] |
---|
21 | | - | else throw("false") |
---|
| 16 | + | func perfomOrder (date) = { |
---|
| 17 | + | let callerAddress = addressFromPublicKey(i.callerPublicKey) |
---|
| 18 | + | let field1 = getDataFromCustomer((toUtf8String(i.callerPublicKey) + "_ORDERS:/GEVISEDI01/Header/Nachrichtentyp_"), callerAddress) |
---|
| 19 | + | if ((field1 == "")) |
---|
| 20 | + | then [StringEntry("_/ORDERS05/IDOC/EDI_DC40/MESTYP_", "sd")] |
---|
| 21 | + | else throw("field empty") |
---|
22 | 22 | | } |
---|
23 | 23 | | |
---|
24 | 24 | | |
---|
Full:
Old | New | | Differences |
---|
1 | 1 | | {-# STDLIB_VERSION 4 #-} |
---|
2 | 2 | | {-# SCRIPT_TYPE ACCOUNT #-} |
---|
3 | 3 | | {-# CONTENT_TYPE DAPP #-} |
---|
4 | | - | func getstoredData (adr) = { |
---|
5 | | - | let test = match getString(adr, "test") { |
---|
| 4 | + | func getDataFromCustomer (key,adr) = { |
---|
| 5 | + | let data = match getString(adr, key) { |
---|
6 | 6 | | case a: String => |
---|
7 | 7 | | a |
---|
8 | 8 | | case _ => |
---|
9 | 9 | | "" |
---|
10 | 10 | | } |
---|
11 | | - | test |
---|
| 11 | + | data |
---|
12 | 12 | | } |
---|
13 | 13 | | |
---|
14 | 14 | | |
---|
15 | 15 | | @Callable(i) |
---|
16 | | - | func storeData () = { |
---|
17 | | - | let account = base58'3MtE2oCkjx6BLhk6tviDComNZYHnohwczd7' |
---|
18 | | - | let testData = getstoredData(Address(account)) |
---|
19 | | - | if ((testData != "")) |
---|
20 | | - | then [StringEntry("mytest_", testData)] |
---|
21 | | - | else throw("false") |
---|
| 16 | + | func perfomOrder (date) = { |
---|
| 17 | + | let callerAddress = addressFromPublicKey(i.callerPublicKey) |
---|
| 18 | + | let field1 = getDataFromCustomer((toUtf8String(i.callerPublicKey) + "_ORDERS:/GEVISEDI01/Header/Nachrichtentyp_"), callerAddress) |
---|
| 19 | + | if ((field1 == "")) |
---|
| 20 | + | then [StringEntry("_/ORDERS05/IDOC/EDI_DC40/MESTYP_", "sd")] |
---|
| 21 | + | else throw("field empty") |
---|
22 | 22 | | } |
---|
23 | 23 | | |
---|
24 | 24 | | |
---|
25 | 25 | | @Verifier(tx) |
---|
26 | 26 | | func verify () = match tx { |
---|
27 | 27 | | case _: DataTransaction => |
---|
28 | 28 | | true |
---|
29 | 29 | | case _: SetScriptTransaction => |
---|
30 | 30 | | true |
---|
31 | 31 | | case _ => |
---|
32 | 32 | | true |
---|
33 | 33 | | } |
---|
34 | 34 | | |
---|