tx · EUyyzvZ1VZSv4hrtHcKDzyy1nSZaqfV86SQee6cF8kAE

3MrYoV4W5mu5ZP8rPspCXveMXusGstSPTjL:  -0.01400000 Waves

2019.09.04 06:30 [660701] smart account 3MrYoV4W5mu5ZP8rPspCXveMXusGstSPTjL > SELF 0.00000000 Waves

{ "type": 13, "id": "EUyyzvZ1VZSv4hrtHcKDzyy1nSZaqfV86SQee6cF8kAE", "fee": 1400000, "feeAssetId": null, "timestamp": 1567567820824, "version": 1, "sender": "3MrYoV4W5mu5ZP8rPspCXveMXusGstSPTjL", "senderPublicKey": "f1NbgbpkRpbigsrHaDkWZAkPgcqd8GM5G5eNmqnTD6z", "proofs": [ "4nA8asZStp5jP8Wb6iEVCHa4LHH8SVju55s9KXxVFFQmXjKCewmFLRwEZHDBomUbdJf6ktwruc1K37iMBfBXurwc" ], "script": "base64:AAIDAAAAAAAAAAAAAAADAAAAAA1hY2NlcHRlZFRva2VuAQAAACDopWq8yndC8nBhMjVKT0WDubke5ZlnF8Nx6tkLoQSt6wAAAAAMY3VycmVudFByaWNlAAAAAAAAAAnEAAAAAARiYW5rAgAAACMzTXpZTGtRNnFDd3RieGFZUTJ5azFrZFV1ZHpiTmc0SmlURwAAAAEAAAAHaW52b2ljZQEAAAATYWdyZWVtZW50VHdvUGFydGllcwAAAAQAAAAEaGFzaAAAAAV0aXRsZQAAAAhhZGRyZXNzMQAAAAhhZGRyZXNzMgQAAAAHcGF5bWVudAkBAAAAB2V4dHJhY3QAAAABCAUAAAAHaW52b2ljZQAAAAdwYXltZW50BAAAAAZhbW91bnQJAQAAAAdleHRyYWN0AAAAAQgFAAAAB3BheW1lbnQAAAAGYW1vdW50BAAAAAJpZAkBAAAAB2V4dHJhY3QAAAABCAUAAAAHaW52b2ljZQAAAA10cmFuc2FjdGlvbklkBAAAAA5wYXltZW50QXNzZXRJZAkBAAAAB2V4dHJhY3QAAAABCAUAAAAHcGF5bWVudAAAAAdhc3NldElkAwkBAAAAAiE9AAAAAgUAAAAOcGF5bWVudEFzc2V0SWQFAAAADWFjY2VwdGVkVG9rZW4JAAACAAAAAQIAAAAvT25seSBwYXltZW50cyBpbiBTSUdOIGFyZSBhbGxvd2VkIGF0IHRoZSBtb21lbnQDCQEAAAACIT0AAAACBQAAAAZhbW91bnQFAAAADGN1cnJlbnRQcmljZQkAAAIAAAABAgAAABJUaGUgcHJpY2UgaXMgd3JvbmcJAQAAAAxTY3JpcHRSZXN1bHQAAAACCQEAAAAIV3JpdGVTZXQAAAABCQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACCQABLAAAAAICAAAABXRpdGxlCQACWAAAAAEFAAAAAmlkBQAAAAV0aXRsZQkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgkAASwAAAACAgAAAARoYXNoCQACWAAAAAEFAAAAAmlkBQAAAARoYXNoCQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACCQABLAAAAAICAAAAAmlkCQACWAAAAAEFAAAAAmlkBQAAAAJpZAkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgkAASwAAAACAgAAAA5jb3VudGVycGFydF8xXwkAAlgAAAABBQAAAAJpZAUAAAAIYWRkcmVzczEJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIJAAEsAAAAAgIAAAAOY291bnRlcnBhcnRfMl8JAAJYAAAAAQUAAAACaWQFAAAACGFkZHJlc3MyBQAAAANuaWwJAQAAAAtUcmFuc2ZlclNldAAAAAEJAARMAAAAAgkBAAAADlNjcmlwdFRyYW5zZmVyAAAAAwkBAAAAHEBleHRyVXNlcihhZGRyZXNzRnJvbVN0cmluZykAAAABBQAAAARiYW5rBQAAAAZhbW91bnQFAAAADWFjY2VwdGVkVG9rZW4FAAAAA25pbAAAAAABi6hj", "chainId": 84, "height": 660701, "spentComplexity": 0 } View: original | compacted Prev: 8tjyoJidoE5Zqvu5ZJyde1dbvcD5UieDan6jiub34s6b Next: 7tyHWAkFiQrUYnSaN4THxsoaCWJpNDGiQEeGSLrb212F Diff:
OldNewDifferences
88 let bank = "3MzYLkQ6qCwtbxaYQ2yk1kdUudzbNg4JiTG"
99
1010 @Callable(invoice)
11-func agreement (couponCode) = {
11+func agreementTwoParties (hash,title,address1,address2) = {
1212 let payment = extract(invoice.payment)
1313 let amount = extract(payment.amount)
14+ let id = extract(invoice.transactionId)
1415 let paymentAssetId = extract(payment.assetId)
1516 if ((paymentAssetId != acceptedToken))
1617 then throw("Only payments in SIGN are allowed at the moment")
1718 else if ((amount != currentPrice))
1819 then throw("The price is wrong")
19- else TransferSet([ScriptTransfer(addressFromStringValue(bank), amount, acceptedToken)])
20+ else ScriptResult(WriteSet([DataEntry(("title" + toBase58String(id)), title), DataEntry(("hash" + toBase58String(id)), hash), DataEntry(("id" + toBase58String(id)), id), DataEntry(("counterpart_1_" + toBase58String(id)), address1), DataEntry(("counterpart_2_" + toBase58String(id)), address2)]), TransferSet([ScriptTransfer(addressFromStringValue(bank), amount, acceptedToken)]))
2021 }
2122
2223
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let acceptedToken = base58'Gf9t8FA4H3ssoZPCwrg3KwUFCci8zuUFP9ssRsUY3s6a'
55
66 let currentPrice = 2500
77
88 let bank = "3MzYLkQ6qCwtbxaYQ2yk1kdUudzbNg4JiTG"
99
1010 @Callable(invoice)
11-func agreement (couponCode) = {
11+func agreementTwoParties (hash,title,address1,address2) = {
1212 let payment = extract(invoice.payment)
1313 let amount = extract(payment.amount)
14+ let id = extract(invoice.transactionId)
1415 let paymentAssetId = extract(payment.assetId)
1516 if ((paymentAssetId != acceptedToken))
1617 then throw("Only payments in SIGN are allowed at the moment")
1718 else if ((amount != currentPrice))
1819 then throw("The price is wrong")
19- else TransferSet([ScriptTransfer(addressFromStringValue(bank), amount, acceptedToken)])
20+ else ScriptResult(WriteSet([DataEntry(("title" + toBase58String(id)), title), DataEntry(("hash" + toBase58String(id)), hash), DataEntry(("id" + toBase58String(id)), id), DataEntry(("counterpart_1_" + toBase58String(id)), address1), DataEntry(("counterpart_2_" + toBase58String(id)), address2)]), TransferSet([ScriptTransfer(addressFromStringValue(bank), amount, acceptedToken)]))
2021 }
2122
2223

github/deemru/w8io/169f3d6 
45.09 ms