tx · ENQTZGeYsYcSHeP1qb44wgvf9BkYLanNCEhq3QAZow2

3NARVJ5Hd5AjdyRHKhAPtT93XP8jKerqHad:  -0.01000000 Waves

2020.02.01 00:43 [879126] smart account 3NARVJ5Hd5AjdyRHKhAPtT93XP8jKerqHad > SELF 0.00000000 Waves

{ "type": 13, "id": "ENQTZGeYsYcSHeP1qb44wgvf9BkYLanNCEhq3QAZow2", "fee": 1000000, "feeAssetId": null, "timestamp": 1580506933777, "version": 1, "sender": "3NARVJ5Hd5AjdyRHKhAPtT93XP8jKerqHad", "senderPublicKey": "5SHN9NGeFwYgWAoSVB6aRtXKcwL4rsg443SPZtdQvaWB", "proofs": [ "2GGLmHQym5vQxEkXaxCFBGRuNFXADrTx1pSVaseNdbasABqdy49rY5AcywvszrU2pkrjmamoUYd59ztj4W2bkXPW" ], "script": "base64:AAIDAAAAAAAAAAcIARIDCgEBAAAAAQEAAAAUdm90ZXJJc0FsbG93ZWRUb1ZvdGUAAAABAAAADnZvdGVyUHVibGljS2V5BAAAAA1hbGVrc2VpUHViS2V5AQAAACB1FNcvDMCUKOMVNo5d3WKdtrx5qE2n0APfGUrHUKhgBwQAAAAKYW5uYVB1YktleQEAAAAgoPN5cAxjfACq6Zs2/04JbmHvXGmOwuYy4YGVLqi1ARkDAwkBAAAAAiE9AAAAAgUAAAAOdm90ZXJQdWJsaWNLZXkFAAAADWFsZWtzZWlQdWJLZXkJAQAAAAIhPQAAAAIFAAAADnZvdGVyUHVibGljS2V5BQAAAAphbm5hUHViS2V5BwcGAAAAAQAAAAFpAQAAAAR2b3RlAAAAAQAAAAd0aGVWb3RlAwkBAAAAASEAAAABCQEAAAAUdm90ZXJJc0FsbG93ZWRUb1ZvdGUAAAABCAUAAAABaQAAAA9jYWxsZXJQdWJsaWNLZXkJAAACAAAAAQIAAAA7WW91IGNhbiBub3Qgdm90ZSBiZWNhdXNlIHlvdSBhcmUgbm90IGluIHRoZSBsaXN0IG9mIHZvdGVycyEEAAAAD2RhdGFGcm9tU3RvcmFnZQkABBoAAAACBQAAAAR0aGlzCQACWAAAAAEIBQAAAAFpAAAAD2NhbGxlclB1YmxpY0tleQMJAQAAAAlpc0RlZmluZWQAAAABBQAAAA9kYXRhRnJvbVN0b3JhZ2UJAAACAAAAAQIAAAA+WW91IGhhdmUgYWxyZWFkeSB2b3RlZCEgVm90aW5nIHRoZSBzZWNvbmQgdGltZSBpcyBub3QgYWxsb3dlZC4JAQAAAAhXcml0ZVNldAAAAAEJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAIJAAJYAAAAAQgFAAAAAWkAAAAPY2FsbGVyUHVibGljS2V5BQAAAAd0aGVWb3RlBQAAAANuaWwAAAAABibvtQ==", "chainId": 84, "height": 879126, "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+func voterIsAllowedToVote (voterPublicKey) = {
5+ let alekseiPubKey = base58'8t38fWQhrYJsqxXtPpiRCEk1g5RJdq9bG5Rkr2N7mDFC'
6+ let annaPubKey = base58'BqHZaEwUMvoF8HKNC69gkHwQwHnw5FX9i67DJSH78z9E'
7+ if (if ((voterPublicKey != alekseiPubKey))
8+ then (voterPublicKey != annaPubKey)
9+ else false)
10+ then false
11+ else true
12+ }
13+
14+
15+@Callable(i)
16+func vote (theVote) = if (!(voterIsAllowedToVote(i.callerPublicKey)))
17+ then throw("You can not vote because you are not in the list of voters!")
18+ else {
19+ let dataFromStorage = getInteger(this, toBase58String(i.callerPublicKey))
20+ if (isDefined(dataFromStorage))
21+ then throw("You have already voted! Voting the second time is not allowed.")
22+ else WriteSet([DataEntry(toBase58String(i.callerPublicKey), theVote)])
23+ }
24+
25+

github/deemru/w8io/026f985 
15.01 ms