tx · 3UKHk4SkBBp3ck3pw1i8kf7WzUTkv5i6JbMoQq5jNTpZ 3N48Q743PKQTUd2PzrWopm3duBnTmV2drNC: -0.01400000 Waves 2020.04.23 10:48 [966836] smart account 3N48Q743PKQTUd2PzrWopm3duBnTmV2drNC > SELF 0.00000000 Waves
{ "type": 13, "id": "3UKHk4SkBBp3ck3pw1i8kf7WzUTkv5i6JbMoQq5jNTpZ", "fee": 1400000, "feeAssetId": null, "timestamp": 1587628135090, "version": 1, "sender": "3N48Q743PKQTUd2PzrWopm3duBnTmV2drNC", "senderPublicKey": "DtgcuFeJCEpayJZvfYkM9WMxVLR2secZksKefiFpsT5k", "proofs": [ "3o2mD9kDVHuk285mCHH4RM5QncpcSmzvHKHoJtcUViXNoSxcsGRNFsLWM7tRBFC5qjaEjoz4U3t2mQb2kwBuHdNs" ], "script": "base64:AAIDAAAAAAAAABMIARIECgIICBIJCgcBCAEICAEBAAAAAAAAAAIAAAABaQEAAAALdXBkYXRlSW5mb3MAAAACAAAABG5hbWUAAAAFaW50cm8EAAAADG93bmVyQWRkcmVzcwgFAAAAAWkAAAAGY2FsbGVyCQEAAAAIV3JpdGVTZXQAAAABCQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACCQABLAAAAAIJAAQlAAAAAQUAAAAMb3duZXJBZGRyZXNzAgAAAAVfbmFtZQUAAAAEbmFtZQkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgkAASwAAAACCQAEJQAAAAEFAAAADG93bmVyQWRkcmVzcwIAAAAGX2ludHJvBQAAAAVpbnRybwUAAAADbmlsAAAAAWkBAAAADWFkZFVwZGF0ZUNhc2UAAAAHAAAAC2lkZW50aWZpYW50AAAABmdlbmRlcgAAAANhZ2UAAAAIbG9jYXRpb24AAAADcGVjAAAABnN0YXR1cwAAAARkYXRlBAAAAAxvd25lckFkZHJlc3MJAAQlAAAAAQgFAAAAAWkAAAAGY2FsbGVyBAAAABFjdXJyZW50Q291bnRlck51bQQAAAAHJG1hd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VudF8JAAGkAAAAAQUAAAAJcGF0aWVudElEAgAAAAdfc3RhdHVzBQAAAAZzdGF0dXMJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIJAAEsAAAAAgkAASwAAAACCQABLAAAAAIFAAAADG93bmVyQWRkcmVzcwIAAAAJX3BhdGllbnRfCQABpAAAAAEFAAAACXBhdGllbnRJRAIAAAAFX2RhdGUFAAAABGRhdGUJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIJAAEsAAAAAgkAASwAAAACCQABLAAAAAIFAAAADG93bmVyQWRkcmVzcwIAAAAJX3BhdGllbnRfCQABpAAAAAEFAAAACXBhdGllbnRJRAIAAAAFX2pzb24FAAAABGpzb24JAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIJAAEsAAAAAgUAAAAMb3duZXJBZGRyZXNzAgAAAAtfY291bnRlck51bQUAAAANdXBkYXRlQ291bnRlcgUAAAADbmlsAAAAAE1dbSM=", "chainId": 84, "height": 966836, "spentComplexity": 0 } View: original | compacted Prev: DNhuT46cAmoninkLo7NkcbM8HB87icUoDLyKTyz4RLRT Next: FKtwyScjFZs2RedCY7zYQxpVb7uXM41KwykpApdfVhLJ Full:
Old | New | Differences | |
---|---|---|---|
1 | 1 | {-# STDLIB_VERSION 3 #-} | |
2 | 2 | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | 3 | {-# CONTENT_TYPE DAPP #-} | |
4 | 4 | ||
5 | 5 | ||
6 | 6 | @Callable(i) | |
7 | 7 | func updateInfos (name,intro) = { | |
8 | 8 | let ownerAddress = i.caller | |
9 | 9 | WriteSet([DataEntry((toString(ownerAddress) + "_name"), name), DataEntry((toString(ownerAddress) + "_intro"), intro)]) | |
10 | 10 | } | |
11 | 11 | ||
12 | 12 | ||
13 | 13 | ||
14 | 14 | @Callable(i) | |
15 | 15 | func addUpdateCase (identifiant,gender,age,location,pec,status,date) = { | |
16 | 16 | let ownerAddress = toString(i.caller) | |
17 | 17 | let currentCounterNum = match getInteger(this, (ownerAddress + "_counterNum")) { | |
18 | 18 | case c: Int => | |
19 | 19 | c | |
20 | 20 | case _ => | |
21 | 21 | 1 | |
22 | 22 | } | |
23 | 23 | let patientID = match getInteger(this, (((ownerAddress + "_patient_") + toString(identifiant)) + "_identifiant")) { | |
24 | 24 | case p: Int => | |
25 | 25 | p | |
26 | 26 | case _ => | |
27 | 27 | (currentCounterNum + 1) | |
28 | 28 | } | |
29 | 29 | let json = (((((((((((((("{\"identifiant\":\"" + toString(patientID)) + "\",\"gender\":\"") + gender) + "\",\"age\":\"") + toString(age)) + "\",\"pec\":\"") + pec) + "\",\"location\":\"") + location) + "\",\"date\":\"") + toString(date)) + "\",\"status\":\"") + toString(status)) + "\"}") | |
30 | 30 | let updateCounter = if ((identifiant == 0)) | |
31 | 31 | then (currentCounterNum + 1) | |
32 | 32 | else currentCounterNum | |
33 | 33 | if (if ((status != 1)) | |
34 | 34 | then (status != 2) | |
35 | 35 | else false) | |
36 | 36 | then throw("Wrong status") | |
37 | 37 | else WriteSet([DataEntry((((ownerAddress + "_patient_") + toString(patientID)) + "_identifiant"), patientID), DataEntry((((ownerAddress + "_patient_") + toString(patientID)) + "_gender"), gender), DataEntry((((ownerAddress + "_patient_") + toString(patientID)) + "_age"), age), DataEntry((((ownerAddress + "_patient_") + toString(patientID)) + "_pec"), pec), DataEntry((((ownerAddress + "_patient_") + toString(patientID)) + "_location"), location), DataEntry((((ownerAddress + "_patient_") + toString(patientID)) + "_status"), status), DataEntry((((ownerAddress + "_patient_") + toString(patientID)) + "_date"), date), DataEntry((((ownerAddress + "_patient_") + toString(patientID)) + "_json"), json), DataEntry((ownerAddress + "_counterNum"), updateCounter)]) | |
38 | 38 | } | |
39 | 39 | ||
40 | 40 |
github/deemru/w8io/026f985 52.21 ms ◑