tx · AH384wpaMq4yhrCTUzNXFKij2JRHhb5AW5Lh8hhwqx9J

3MvqUEAdK8oa1jDS82eqYYVoHTX3S71rRPa:  -0.01400000 Waves

2019.09.08 14:57 [667073] smart account 3MvqUEAdK8oa1jDS82eqYYVoHTX3S71rRPa > SELF 0.00000000 Waves

{ "type": 13, "id": "AH384wpaMq4yhrCTUzNXFKij2JRHhb5AW5Lh8hhwqx9J", "fee": 1400000, "feeAssetId": null, "timestamp": 1567943896186, "version": 1, "sender": "3MvqUEAdK8oa1jDS82eqYYVoHTX3S71rRPa", "senderPublicKey": "HktRLq8bnL31myXeh7WVXAuMw8Qb7yrhPfMVxucQVeU", "proofs": [ "eTshw88XpZ1u98FHVDjemRUL9nKtj7GEKYp4iHhDAW87odMhjZvi7nhUDKxWbMBJA1DaionDSid1rUFbE66xMud" ], "script": "base64:AAIDAAAAAAAAAAAAAAABAAAAAAhudWxsSG9tZQIAAAABMAAAAAIAAAABaQEAAAAHc2V0aG9tZQAAAAEAAAAGaG9tZUlkBAAAAAxzZWxsZXJCYXNlNTgJAAJYAAAAAQgIBQAAAAFpAAAABmNhbGxlcgAAAAVieXRlcwQAAAAFd3JpdGUJAQAAAAhXcml0ZVNldAAAAAEJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIFAAAADHNlbGxlckJhc2U1OAUAAAAGaG9tZUlkCQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACAgAAAApzZXRob21lTG9nCQABLAAAAAIJAAEsAAAAAgUAAAAMc2VsbGVyQmFzZTU4AgAAAAQgLT4gBQAAAAZob21lSWQFAAAAA25pbAkBAAAADFNjcmlwdFJlc3VsdAAAAAIFAAAABXdyaXRlCQEAAAALVHJhbnNmZXJTZXQAAAABBQAAAANuaWwAAAABaQEAAAAEbWFpbgAAAAIAAAAGaG9tZUlkAAAAB2FkZHJlc3MEAAAAA3BtdAkBAAAAB2V4dHJhY3QAAAABCAUAAAABaQAAAAdwYXltZW50AwkBAAAACWlzRGVmaW5l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AAAQkAASwAAAACAgAAABxzYWxsZXIgZG9lc24ndCBvd24gYSBob3VzZTogBQAAAAZob21lSWQJAAACAAAAAQIAAAAPc2FsbGVyIGhvbWVsZXNzCQAAAgAAAAECAAAAD0ludmFsaWQgYWRkcmVzcwAAAADAZWGJ", "chainId": 84, "height": 667073, "spentComplexity": 0 } View: original | compacted Prev: A8E2ZTyJqvFnB2gHk6i2NbxG7xVz23ASTKXaqhPYdum Next: none Diff:
OldNewDifferences
2323 case addressObject: Address =>
2424 match getString(this, address) {
2525 case home: String =>
26- let transfer = TransferSet([ScriptTransfer(addressObject, pmt.amount, pmt.assetId)])
27- let write = WriteSet([DataEntry(address, nullHome), DataEntry(buerBase58, homeId), DataEntry("mainLog", ((address + " -> ") + buerBase58))])
28- ScriptResult(write, transfer)
26+ if ((home == "0"))
27+ then throw("saller homeless")
28+ else if ((home == homeId))
29+ then {
30+ let transfer = TransferSet([ScriptTransfer(addressObject, pmt.amount, pmt.assetId)])
31+ let write = WriteSet([DataEntry(address, nullHome), DataEntry(buerBase58, homeId), DataEntry("mainLog", ((address + " -> ") + buerBase58))])
32+ ScriptResult(write, transfer)
33+ }
34+ else throw(("saller doesn't own a house: " + homeId))
2935 case _ =>
3036 throw("saller homeless")
3137 }
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let nullHome = "0"
55
66 @Callable(i)
77 func sethome (homeId) = {
88 let sellerBase58 = toBase58String(i.caller.bytes)
99 let write = WriteSet([DataEntry(sellerBase58, homeId), DataEntry("sethomeLog", ((sellerBase58 + " -> ") + homeId))])
1010 ScriptResult(write, TransferSet(nil))
1111 }
1212
1313
1414
1515 @Callable(i)
1616 func main (homeId,address) = {
1717 let pmt = extract(i.payment)
1818 if (isDefined(pmt.assetId))
1919 then throw("payment is only waves")
2020 else {
2121 let buerBase58 = toBase58String(i.caller.bytes)
2222 match addressFromString(address) {
2323 case addressObject: Address =>
2424 match getString(this, address) {
2525 case home: String =>
26- let transfer = TransferSet([ScriptTransfer(addressObject, pmt.amount, pmt.assetId)])
27- let write = WriteSet([DataEntry(address, nullHome), DataEntry(buerBase58, homeId), DataEntry("mainLog", ((address + " -> ") + buerBase58))])
28- ScriptResult(write, transfer)
26+ if ((home == "0"))
27+ then throw("saller homeless")
28+ else if ((home == homeId))
29+ then {
30+ let transfer = TransferSet([ScriptTransfer(addressObject, pmt.amount, pmt.assetId)])
31+ let write = WriteSet([DataEntry(address, nullHome), DataEntry(buerBase58, homeId), DataEntry("mainLog", ((address + " -> ") + buerBase58))])
32+ ScriptResult(write, transfer)
33+ }
34+ else throw(("saller doesn't own a house: " + homeId))
2935 case _ =>
3036 throw("saller homeless")
3137 }
3238 case _ =>
3339 throw("Invalid address")
3440 }
3541 }
3642 }
3743
3844

github/deemru/w8io/026f985 
21.18 ms