tx · 4w2f1F8Q6euT75xyLoeUkKyZNXfCgBzppjffUBQiVkiV

3N5YzdqDE6FDdsLNGXU4G4yrmirb2oiifEc:  -0.01000000 Waves

2022.10.19 14:11 [2279198] smart account 3N5YzdqDE6FDdsLNGXU4G4yrmirb2oiifEc > SELF 0.00000000 Waves

{ "type": 13, "id": "4w2f1F8Q6euT75xyLoeUkKyZNXfCgBzppjffUBQiVkiV", "fee": 1000000, "feeAssetId": null, "timestamp": 1666178027140, "version": 2, "chainId": 84, "sender": "3N5YzdqDE6FDdsLNGXU4G4yrmirb2oiifEc", "senderPublicKey": "E3rsNDJ7CyVzRYUkm1k4GYLuZYYxzQioRgWedzPYXTSL", "proofs": [ "1q8VP8Rr5pSp2Mv7bGLP8SZMwK7fwujeSxJvezdzngYosuSLLK41cmZFQQfFY8ESj43LNrNXPuxX9rCe5Tuc4Pa" ], "script": "base64:AAIFAAAAAAAAABIIAhIDCgEIEgQKAgEBEgMKAQgAAAAGAAAAAAl2b3RlQXNzZXQBAAAAIC03E4HTJDddn+FvdtPRD5PvLCz03YmtXEpW6HzJAXIbAAAAAA9uZXdQdXJwb3NlUHJpY2UAAAAAAlQL5AAAAAAADHZvdGVEdXJhdGlvbgkAAGgAAAACAAAAAAAAAAAHAAAAAAAAAAWgAAAAAA1uZXdQdXJwb3NlS2V5AgAAAAdwdXJwb3NlAAAAAAxwdXJwb3NlSWRLZXkCAAAACXB1cnBvc2VJZAEAAAALaXNQYXltZW50T2sAAAABAAAAAWkEAAAAEWFjY2VwdGFibGVBc3NldElkBQAAAAl2b3RlQXNzZXQDCQAAAAAAAAIJAAGQAAAAAQgFAAAAAWkAAAAIcGF5bWVudHMAAAAAAAAAAAAJAAACAAAAAQIAAAAUUGF5bWVudCBub3QgYXR0YWNoZWQEAAAAAXAJAAGRAAAAAggFAAAAAWkAAAAIcGF5bWVudHMAAAAAAAAAAAAEAAAAByRtYXRjaDAIBQAAAAFwAAAAB2Fzc2V0SWQDCQAAAQAAAAIFAAAA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c3RWb3RlQmxvY2sFAAAADWZpcnN0Vm90ZUNhc3QJAARMAAAAAgkBAAAADEludGVnZXJFbnRyeQAAAAIJAAEsAAAAAgkAASwAAAACCQABLAAAAAIJAAEsAAAAAgkAASwAAAACBQAAAA1uZXdQdXJwb3NlS2V5AgAAAAFfCQABpAAAAAEFAAAACXB1cnBvc2VJZAIAAAABXwUAAAAKY3VycmVudEtleQIAAAAQX3dhbGxldFRvdGFsVm90ZQkAAGQAAAACBQAAAAZhbW91bnQFAAAAD3dhbGxldFRvdGFsVm90ZQUAAAADbmlsCQAAAgAAAAECAAAAF25vdGhpbmcgdG8gZG8gbXkgZnJpZW5kAAAAAWkBAAAABkRlbGV0ZQAAAAEAAAAFZW50cnkJAARMAAAAAgkBAAAAC0RlbGV0ZUVudHJ5AAAAAQUAAAAFZW50cnkFAAAAA25pbAAAAAD4xdkV", "height": 2279198, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: 91z3LQVQakLA9uZyr2xjDTsJezVHQ5DQFbCxgYA6f8Po Next: 8oHgXYgRrJW3nK8ZkE3CqQ7fEiVVzk1ShjLurnKBxwQX Diff:
OldNewDifferences
4545 let endHeight = (height + voteDuration)
4646 let text = toBase64String(toBytes(purpose))
4747 let id = (purposeId + 1)
48-[StringEntry(((newPurposeKey + "_") + toString(id)), text), IntegerEntry(purposeIdKey, id), StringEntry((((newPurposeKey + "_") + toString(id)) + "_duration"), ((toString(startHeight) + "_") + toString(endHeight))), StringEntry((((newPurposeKey + "_") + toString(id)) + "_owner"), currentKey)]
48+[StringEntry((((newPurposeKey + "_") + toString(id)) + "_text"), text), IntegerEntry(purposeIdKey, id), StringEntry((((newPurposeKey + "_") + toString(id)) + "_duration"), ((toString(startHeight) + "_") + toString(endHeight))), StringEntry((((newPurposeKey + "_") + toString(id)) + "_owner"), currentKey)]
4949 }
5050 }
5151
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 5 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let voteAsset = base58'43W4FcqA1rEpSmUGHoGiXvpSLfhadws9LS5j3SJsKxxS'
55
66 let newPurposePrice = 10000000000
77
88 let voteDuration = (7 * 1440)
99
1010 let newPurposeKey = "purpose"
1111
1212 let purposeIdKey = "purposeId"
1313
1414 func isPaymentOk (i) = {
1515 let acceptableAssetId = voteAsset
1616 if ((size(i.payments) == 0))
1717 then throw("Payment not attached")
1818 else {
1919 let p = i.payments[0]
2020 match p.assetId {
2121 case assetId: ByteVector =>
2222 if ((assetId == acceptableAssetId))
2323 then (p.amount == newPurposePrice)
2424 else false
2525 case _ =>
2626 throw("Wrong payment asset")
2727 }
2828 }
2929 }
3030
3131
3232 @Callable(i)
3333 func newPurpose (purpose) = {
3434 let stringSize = size(toBytes(purpose))
3535 let currentKey = toBase58String(i.caller.bytes)
3636 let purposeId = valueOrElse(getInteger(this, purposeIdKey), 0)
3737 if (if ((stringSize > 200))
3838 then true
3939 else (10 > stringSize))
4040 then throw("Purpose text cannot be more than 200")
4141 else if (!(isPaymentOk(i)))
4242 then throw(("you have to pay " + toString(newPurposePrice)))
4343 else {
4444 let startHeight = height
4545 let endHeight = (height + voteDuration)
4646 let text = toBase64String(toBytes(purpose))
4747 let id = (purposeId + 1)
48-[StringEntry(((newPurposeKey + "_") + toString(id)), text), IntegerEntry(purposeIdKey, id), StringEntry((((newPurposeKey + "_") + toString(id)) + "_duration"), ((toString(startHeight) + "_") + toString(endHeight))), StringEntry((((newPurposeKey + "_") + toString(id)) + "_owner"), currentKey)]
48+[StringEntry((((newPurposeKey + "_") + toString(id)) + "_text"), text), IntegerEntry(purposeIdKey, id), StringEntry((((newPurposeKey + "_") + toString(id)) + "_duration"), ((toString(startHeight) + "_") + toString(endHeight))), StringEntry((((newPurposeKey + "_") + toString(id)) + "_owner"), currentKey)]
4949 }
5050 }
5151
5252
5353
5454 @Callable(i)
5555 func vote4EnnoDAO (purposeId,vote) = {
5656 let getDuration = valueOrErrorMessage(getString(this, (((newPurposeKey + "_") + toString(purposeId)) + "_duration")), "purpose not found")
5757 let duration = split(getDuration, "_")
5858 let startHeight = valueOrElse(parseInt(duration[0]), 0)
5959 let endHeight = valueOrElse(parseInt(duration[1]), 0)
6060 let currentKey = toBase58String(i.caller.bytes)
6161 if (if ((startHeight > height))
6262 then true
6363 else (height > endHeight))
6464 then throw(("voting period is over for purpose: " + toString(purposeId)))
6565 else if (if ((0 >= vote))
6666 then true
6767 else (vote > 2))
6868 then throw("vote must be yes or no")
6969 else {
7070 let amount = i.payments[0].amount
7171 let lockTill = (height + voteDuration)
7272 if (if ((0 >= amount))
7373 then true
7474 else (i.payments[0].assetId != voteAsset))
7575 then throw("invalid token attached")
7676 else {
7777 let totalVote = valueOrElse(getInteger(this, (((newPurposeKey + "_") + toString(purposeId)) + "_totalVote")), 0)
7878 let walletTotalVote = valueOrElse(getInteger(this, ((((newPurposeKey + "_") + toString(purposeId)) + currentKey) + "_walletTotalVote")), 0)
7979 let firstVoteCast = valueOrElse(getInteger(this, (((((newPurposeKey + "_") + toString(purposeId)) + "_") + currentKey) + "_firstVoteBlock")), height)
8080 if ((vote == 1))
8181 then {
8282 let getYes = valueOrElse(getInteger(this, (((newPurposeKey + "_") + toString(purposeId)) + "_yes")), 0)
8383 let getYesUser = valueOrElse(getInteger(this, (((((newPurposeKey + "_") + toString(purposeId)) + "_") + currentKey) + "_yes")), 0)
8484 let total = (getYes + amount)
8585 [IntegerEntry((((((newPurposeKey + "_") + toString(purposeId)) + "_") + currentKey) + "_yes"), (getYesUser + amount)), IntegerEntry((((newPurposeKey + "_") + toString(purposeId)) + "_yes"), total), IntegerEntry((((newPurposeKey + "_") + toString(purposeId)) + "_totalVote"), (amount + totalVote)), IntegerEntry((((((newPurposeKey + "_") + toString(purposeId)) + "_") + currentKey) + "_firstVoteBlock"), firstVoteCast), IntegerEntry((((((newPurposeKey + "_") + toString(purposeId)) + "_") + currentKey) + "_walletTotalVote"), (amount + walletTotalVote))]
8686 }
8787 else if ((vote == 2))
8888 then {
8989 let getNo = valueOrElse(getInteger(this, (((newPurposeKey + "_") + toString(purposeId)) + "_no")), 0)
9090 let getNoUser = valueOrElse(getInteger(this, (((((newPurposeKey + "_") + toString(purposeId)) + "_") + currentKey) + "_no")), 0)
9191 let total = (getNo + amount)
9292 [IntegerEntry((((((newPurposeKey + "_") + toString(purposeId)) + "_") + currentKey) + "_no"), (getNoUser + amount)), IntegerEntry((((newPurposeKey + "_") + toString(purposeId)) + "_no"), total), IntegerEntry((((newPurposeKey + "_") + toString(purposeId)) + "_totalVote"), (amount + totalVote)), IntegerEntry((((((newPurposeKey + "_") + toString(purposeId)) + "_") + currentKey) + "_firstVoteBlock"), firstVoteCast), IntegerEntry((((((newPurposeKey + "_") + toString(purposeId)) + "_") + currentKey) + "_walletTotalVote"), (amount + walletTotalVote))]
9393 }
9494 else throw("nothing to do my friend")
9595 }
9696 }
9797 }
9898
9999
100100
101101 @Callable(i)
102102 func Delete (entry) = [DeleteEntry(entry)]
103103
104104

github/deemru/w8io/026f985 
76.74 ms