tx · 45judDQPh84UF2nJeUPn5v6BAkXsAvtvLuvZRMutswpb
3MxH4ABV9tA1qpHhNDv6wmswuioTTjAsjF5: -1.00000000 Waves
2019.03.21 20:05 [546333] smart asset 3MxH4ABV9tA1qpHhNDv6wmswuioTTjAsjF5 > SELF 0.00000000 Token
{
"type": 15,
"id": "45judDQPh84UF2nJeUPn5v6BAkXsAvtvLuvZRMutswpb",
"fee": 100000000,
"feeAssetId": null,
"timestamp": 1553187929936,
"version": 1,
"sender": "3MxH4ABV9tA1qpHhNDv6wmswuioTTjAsjF5",
"senderPublicKey": "BjncHcZ1KwcHLGe7xdxfaYsCEhQk3eTTtVpjjqEcCLBj",
"proofs": [
"4AhTwx8pDdPjm6xsrJkLzjyYjZXwHZXoqRYoCDkVizZjvtBH43MDY2CVY8MCCAR8YiiGHAeWNTQtTcLmhukg9yaV"
],
"assetId": "7JJgTXQm4gsDFkUk7PoNDidkdYBjN9BJQtcmr4Bbfjoa",
"script": "base64:AgQAAAAGaXNzdWVyCQEAAAAHQWRkcmVzcwAAAAEBAAAAGgFUW7hkcH0hU14f4lhGQOrki5V820P/5PQ4BAAAAAdhc3NldElkAQAAACBdlPyKlpD5iwqaN+I1F55Omh9+m5ZQyXa2N5gCtxzsBQQAAAAHJG1hdGNoMAUAAAACdHgDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAE0V4Y2hhbmdlVHJhbnNhY3Rpb24EAAAAAmV4BQAAAAckbWF0Y2gwBAAAAARwYWlyCQEAAAAJQXNzZXRQYWlyAAAAAgUAAAAHYXNzZXRJZAUAAAAEdW5pdAQAAAAEcmF0ZQkBAAAAB2V4dHJhY3QAAAABCQAEGgAAAAIFAAAABmlzc3VlcgIAAAAMZXhjaGFuZ2VSYXRlBAAAAAhyYXRlRGlmZgkAAGUAAAACBQAAAARyYXRlCQAAawAAAAMAAAAAAAX14QAIBQAAAAJleAAAAAVwcmljZQgFAAAAAmV4AAAABmFtb3VudAMDCQAAAAAAAAIICAUAAAACZXgAAAAIYnV5T3JkZXIAAAAJYXNzZXRQYWlyBQAAAARwYWlyCQAAZgAAAAIFAAAACHJhdGVEaWZmAP////////+cBwkAAGYAAAACAAAAAAAAAABkBQAAAAhyYXRlRGlmZgcGBYmDYg==",
"chainId": 84,
"height": 546333,
"spentComplexity": 0
}
View: original | compacted
Prev: none
Next: 7Rzbp4aYMM8hd8tV24Dha9eKTKcpuEJLkGDKBdGHfjCB
Full:
Old | New | | Differences |
---|
1 | | - | # no script |
---|
| 1 | + | {-# STDLIB_VERSION 2 #-} |
---|
| 2 | + | {-# CONTENT_TYPE EXPRESSION #-} |
---|
| 3 | + | let issuer = Address(base58'3MxH4ABV9tA1qpHhNDv6wmswuioTTjAsjF5') |
---|
| 4 | + | let assetId = base58'7JJgTXQm4gsDFkUk7PoNDidkdYBjN9BJQtcmr4Bbfjoa' |
---|
| 5 | + | match tx { |
---|
| 6 | + | case ex: ExchangeTransaction => |
---|
| 7 | + | let pair = AssetPair(assetId, unit) |
---|
| 8 | + | let rate = extract(getInteger(issuer, "exchangeRate")) |
---|
| 9 | + | let rateDiff = (rate - fraction(100000000, ex.price, ex.amount)) |
---|
| 10 | + | if (if ((ex.buyOrder.assetPair == pair)) |
---|
| 11 | + | then (rateDiff > -100) |
---|
| 12 | + | else false) |
---|
| 13 | + | then (100 > rateDiff) |
---|
| 14 | + | else false |
---|
| 15 | + | case _ => |
---|
| 16 | + | true |
---|
| 17 | + | } |
---|