tx · 6BcPgKBDTgLuyj2oE1NLXPY4VPw3vfUDieJc8DgpsBan

3N4LzC1y7z1TCGFsHcCPczYTB1gWPxoS1qR:  -0.01000000 Waves

2020.10.16 18:54 [1223342] smart account 3N4LzC1y7z1TCGFsHcCPczYTB1gWPxoS1qR > SELF 0.00000000 Waves

{ "type": 13, "id": "6BcPgKBDTgLuyj2oE1NLXPY4VPw3vfUDieJc8DgpsBan", "fee": 1000000, "feeAssetId": null, "timestamp": 1602863715246, "version": 2, "chainId": 84, "sender": "3N4LzC1y7z1TCGFsHcCPczYTB1gWPxoS1qR", "senderPublicKey": "7U1B1sCXB8iUTh12FbZUspDfnVQVeQhU45UjAhZbUfUm", "proofs": [ "3PWmeeCbP6JEy9rxxDhiwYf38T44C3gAEUxHAhAfa2wAg9UdStQWg4vHnqhRiLJy6rieN24oVjxEcVn62LYCLwF2" ], "script": "base64:AAIDAAAAAAAAAAsIARIAEgMKAQESAAAAAAAAAAADAAAAAWkBAAAAB2RlcG9zaXQAAAAABAAAAA9Db2xsYXRlcmFsVG9rZW4BAAAAIEXAbIcI8kUexOI20CBj9o7wm7aY+dhr4NqLF5bb9v1DBAAAAANwbXQJAQAAAAdleHRyYWN0AAAAAQgFAAAAAWkAAAAHcGF5bWVudAMDCQEAAAAJaXNEZWZpbmVkAAAAAQgFAAAAA3BtdAAAAAdhc3NldElkCQAAAAAAAAIJAQAAAAdleHRyYWN0AAAAAQgFAAAAA3BtdAAAAAdhc3NldElkBQAAAA9Db2xsYXRlcmFsVG9rZW4HBAAAAApjdXJyZW50S2V5CQACWAAAAAEICAUAAAABaQAAAAZjYWxsZXIAAAAFYnl0ZXMEAAAADWN1cnJlbnRBbW91bnQEAAAAByRtYXRjaDAJAAQaAAAAAgUAAAAEdGhpcwUAAAAKY3VycmVudEtleQMJAAABAAAAAgUAAAAHJG1hdGNoMAIAAAADSW50BAAAAAFhBQAAAAckbWF0Y2gwBQAAAAFhAAAAAAAAAAAABAAAAAluZXdBbW91bnQJAAB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grZqRPS5vvLPGg8zQQAAAAKY3VycmVudEtleQkAAlgAAAABCAgFAAAAAWkAAAAGY2FsbGVyAAAABWJ5dGVzBAAAAA1jdXJyZW50QW1vdW50BAAAAAckbWF0Y2gwCQAEGgAAAAIFAAAABHRoaXMFAAAACmN1cnJlbnRLZXkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAAA0ludAQAAAABYQUAAAAHJG1hdGNoMAUAAAABYQAAAAAAAAAAAAQAAAAJbmV3QW1vdW50CQAAZQAAAAIFAAAADWN1cnJlbnRBbW91bnQAAAAAAAAAAAoDCQAAZgAAAAIAAAAAAAAAAAAFAAAACW5ld0Ftb3VudAkAAAIAAAABAgAAAC1Ob3QgZW5vdWdoIEdvdmVybmFuY2UgYmFsYW5jZSBpbiB0aGUgQ29udHJhY3QJAQAAAAxTY3JpcHRSZXN1bHQAAAACCQEAAAAIV3JpdGVTZXQAAAABCQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACBQAAAApjdXJyZW50S2V5BQAAAAluZXdBbW91bnQFAAAAA25pbAkBAAAAC1RyYW5zZmVyU2V0AAAAAQkABEwAAAACCQEAAAAOU2NyaXB0VHJhbnNmZXIAAAADCAUAAAABaQAAAAZjYWxsZXIAAAAAAAAAAAoFAAAAC0dvdmVyblRva2VuBQAAAANuaWwAAAAAaKdk8w==", "height": 1223342, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: none Next: none Full:
OldNewDifferences
1-# no script
1+{-# STDLIB_VERSION 3 #-}
2+{-# SCRIPT_TYPE ACCOUNT #-}
3+{-# CONTENT_TYPE DAPP #-}
4+
5+
6+@Callable(a)
7+func deposit () = {
8+ let b = base58'5hHK64aujiyn7cNrTBwhe5yJQuxs119KTPbE9nFjLoUN'
9+ let c = extract(a.payment)
10+ if (if (isDefined(c.assetId))
11+ then (extract(c.assetId) == b)
12+ else false)
13+ then {
14+ let d = toBase58String(a.caller.bytes)
15+ let e = {
16+ let f = getInteger(this, d)
17+ if ($isInstanceOf(f, "Int"))
18+ then {
19+ let g = f
20+ g
21+ }
22+ else 0
23+ }
24+ let h = (e + c.amount)
25+ WriteSet([DataEntry(d, h)])
26+ }
27+ else throw("Can deposit only MyToken")
28+ }
29+
30+
31+
32+@Callable(a)
33+func withdraw (i) = {
34+ let d = toBase58String(a.caller.bytes)
35+ let e = {
36+ let f = getInteger(this, d)
37+ if ($isInstanceOf(f, "Int"))
38+ then {
39+ let g = f
40+ g
41+ }
42+ else 0
43+ }
44+ let h = (e - i)
45+ if ((0 > i))
46+ then throw("Can't withdraw negative amount")
47+ else if ((0 > h))
48+ then throw("Not enough balance")
49+ else ScriptResult(WriteSet([DataEntry(d, h)]), TransferSet([ScriptTransfer(a.caller, i, unit)]))
50+ }
51+
52+
53+
54+@Callable(a)
55+func payYield () = {
56+ let j = base58'DeyMK8USWs9ijzAXNy2azA3soajfrXjUNiJBdSJJsvMJ'
57+ let d = toBase58String(a.caller.bytes)
58+ let e = {
59+ let f = getInteger(this, d)
60+ if ($isInstanceOf(f, "Int"))
61+ then {
62+ let g = f
63+ g
64+ }
65+ else 0
66+ }
67+ let h = (e - 10)
68+ if ((0 > h))
69+ then throw("Not enough Governance balance in the Contract")
70+ else ScriptResult(WriteSet([DataEntry(d, h)]), TransferSet([ScriptTransfer(a.caller, 10, j)]))
71+ }
72+
73+

github/deemru/w8io/169f3d6 
24.61 ms