tx · 2yWDvu2q89GZkxDJoydYDbAucwZ2uuCBLscrP3Lte5YY

3N8dYK8BQhY7z1yKFRFhdw4m9b4JjsNQJVd:  -0.01400000 Waves

2023.04.14 17:31 [2534325] smart account 3N8dYK8BQhY7z1yKFRFhdw4m9b4JjsNQJVd > SELF 0.00000000 Waves

{ "type": 13, "id": "2yWDvu2q89GZkxDJoydYDbAucwZ2uuCBLscrP3Lte5YY", "fee": 1400000, "feeAssetId": null, "timestamp": 1681482704324, "version": 2, "chainId": 84, "sender": "3N8dYK8BQhY7z1yKFRFhdw4m9b4JjsNQJVd", "senderPublicKey": "AK6rRKpHobxNveEtJE5BBXbdwm9BpGL7ewP9Xb6VYuHx", "proofs": [ "4a5ABA7yFdFKdZ43jaevAWi1zPNELRyEmxp9VqrRK17X9SUbFkci63DDWZoh2uCJiTW851DprENksa2dhsXp4D8R" ], "script": "base64:AAIEAAAAAAAAAA4IAhIFCgMIAQESAwoBAQAAAAcAAAAADkE0QVN0YWtpbmdEQXBwCQEAAAARQGV4dHJOYXRpdmUoMTA2MikAAAABAgAAACMzTjZvV0x5UVkyZ003UVVrVXZCbWUxUkVuQTZkMVY3eTNBVAAAAAAidm90aW5nX3RpbWVzdGFtcF9jb250cm9sbGVyX3B1YmtleQEAAAAgO3RF8b5QOeRSsZiONgCOv+riQ9YfIBAqDV0YsQ0EQwwAAAAAEmNvbnRyb2xsZXJfYWRkcmVzcwkBAAAAFGFkZHJlc3NGcm9tUHVibGljS2V5AAAAAQUAAAAidm90aW5nX3RpbWVzdGFtcF9jb250cm9sbGVyX3B1YmtleQAAAAAMbGF1bmNoX2Vycm9yAgAAACREYXBwIHdpbGwgc3RhcnQgVm90aW5nIGF0IFRpbWVzdGFtcCAAAAAAA21zZwIAAAAuPGgxPllvdXIgVm90ZSBTdWJtaXR0ZWQgU3VjY2Vzc2Z1bGx5ITwvaDE+PGJyPgAAAAARQWxyZWFkeVZvdGVkRXJyb3ICAAAAPlRoaXMgQWRkcmVzcyBBbHJ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VyRW50cnkAAAACCQABLAAAAAIJAAEsAAAAAgkAASwAAAACAgAAAAZUb3RhbF8FAAAAB1ZvdGVBc3QCAAAAAV8JAAGkAAAAAQUAAAALUG9ycG9zYWxfSUQFAAAABEFUVk8JAARMAAAAAgkBAAAADEludGVnZXJFbnRyeQAAAAIJAAEsAAAAAgkAASwAAAACBQAAAAZwdWJrZXkCAAAAAV8JAAGkAAAAAQUAAAALUG9ycG9zYWxfSUQFAAAAGExhdGVzdFVzZXJDb3VudGZvclZvdGluZwkABEwAAAACCQEAAAALU3RyaW5nRW50cnkAAAACCQABLAAAAAICAAAADlF1b3J1bV9TdGF0dXNfCQABpAAAAAEFAAAAC1BvcnBvc2FsX0lEAgAAAARQYXNzCQAETAAAAAIJAQAAAAtTdHJpbmdFbnRyeQAAAAIJAAEsAAAAAgIAAAAQUHJvcG9zYWxfU3RhdHVzXwkAAaQAAAABBQAAAAtQb3Jwb3NhbF9JRAIAAAAIUGFzcy1ZZXMJAARMAAAAAgkBAAAAC1N0cmluZ0VudHJ5AAAAAgIAAAAHbWVzc2FnZQUAAAADbXNnBQAAAANuaWwJAAACAAAAAQIAAAAUV3JvbmcgVmFsdWUgRW50ZXJlZC4AAAABAAAAAnR4AQAAAAZ2ZXJpZnkAAAAACQAB9AAAAAMIBQAAAAJ0eAAAAAlib2R5Qnl0ZXMJAAGRAAAAAggFAAAAAnR4AAAABnByb29mcwAAAAAAAAAAAAgFAAAAAnR4AAAAD3NlbmRlclB1YmxpY0tlecUfkQY=", "height": 2534325, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: E2GuSsvnQQECUi5VpB4WpnjzFGZ2sFpHMEGiXNPERBvR Next: 9EMbc4R9FmAPC8DTZR7cPHGSCcfWt1GkMgBotcYeJ7um Diff:
OldNewDifferences
7272 then throw((launch_error + toString(StartTS)))
7373 else if ((lastBlock.timestamp > EndTS))
7474 then throw(voteErr)
75- else if ((readQuoraumValue > totalvotes))
76- then [IntegerEntry(("Total_Votes_" + toString(Porposal_ID)), totalvotes), IntegerEntry(((("Total_" + VoteAst) + "_") + toString(Porposal_ID)), ATVO), IntegerEntry(((pubkey + "_") + toString(Porposal_ID)), LatestUserCountforVoting), StringEntry(("Quorum_Status_" + toString(Porposal_ID)), "Fail"), StringEntry("message", msg)]
77- else if ((totalvotes > readQuoraumValue))
78- then [IntegerEntry(("Total_Votes_" + toString(Porposal_ID)), totalvotes), IntegerEntry(((("Total_" + VoteAst) + "_") + toString(Porposal_ID)), ATVO), IntegerEntry(((pubkey + "_") + toString(Porposal_ID)), LatestUserCountforVoting), StringEntry(("Quorum_Status_" + toString(Porposal_ID)), "Pass"), StringEntry("message", msg)]
79- else nil
75+ else if (if ((readQuoraumValue > totalvotes))
76+ then (readTotalNoVotesValue > ATVO)
77+ else false)
78+ then [IntegerEntry(("Total_Votes_" + toString(Porposal_ID)), totalvotes), IntegerEntry(((("Total_" + VoteAst) + "_") + toString(Porposal_ID)), ATVO), IntegerEntry(((pubkey + "_") + toString(Porposal_ID)), LatestUserCountforVoting), StringEntry(("Quorum_Status_" + toString(Porposal_ID)), "Fail"), StringEntry(("Proposal_Status_" + toString(Porposal_ID)), "Rejected"), StringEntry("message", msg)]
79+ else if (if ((readQuoraumValue > totalvotes))
80+ then (ATVO > readTotalNoVotesValue)
81+ else false)
82+ then [IntegerEntry(("Total_Votes_" + toString(Porposal_ID)), totalvotes), IntegerEntry(((("Total_" + VoteAst) + "_") + toString(Porposal_ID)), ATVO), IntegerEntry(((pubkey + "_") + toString(Porposal_ID)), LatestUserCountforVoting), StringEntry(("Quorum_Status_" + toString(Porposal_ID)), "Fail"), StringEntry(("Proposal_Status_" + toString(Porposal_ID)), "Rejected"), StringEntry("message", msg)]
83+ else if (if ((totalvotes > readQuoraumValue))
84+ then (readTotalNoVotesValue > ATVO)
85+ else false)
86+ then [IntegerEntry(("Total_Votes_" + toString(Porposal_ID)), totalvotes), IntegerEntry(((("Total_" + VoteAst) + "_") + toString(Porposal_ID)), ATVO), IntegerEntry(((pubkey + "_") + toString(Porposal_ID)), LatestUserCountforVoting), StringEntry(("Quorum_Status_" + toString(Porposal_ID)), "Pass"), StringEntry(("Proposal_Status_" + toString(Porposal_ID)), "Pass-No"), StringEntry("message", msg)]
87+ else if (if ((totalvotes > readQuoraumValue))
88+ then (ATVO > readTotalNoVotesValue)
89+ else false)
90+ then [IntegerEntry(("Total_Votes_" + toString(Porposal_ID)), totalvotes), IntegerEntry(((("Total_" + VoteAst) + "_") + toString(Porposal_ID)), ATVO), IntegerEntry(((pubkey + "_") + toString(Porposal_ID)), LatestUserCountforVoting), StringEntry(("Quorum_Status_" + toString(Porposal_ID)), "Pass"), StringEntry(("Proposal_Status_" + toString(Porposal_ID)), "Pass-Yes"), StringEntry("message", msg)]
91+ else throw("Wrong Value Entered.")
8092 }
8193
8294
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 4 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 let A4AStakingDApp = addressFromStringValue("3N6oWLyQY2gM7QUkUvBme1REnA6d1V7y3AT")
55
66 let voting_timestamp_controller_pubkey = base58'515tSAyMUbAb8kKjcpGDpqALGfCgcwfWmWKKkcBKTcGB'
77
88 let controller_address = addressFromPublicKey(voting_timestamp_controller_pubkey)
99
1010 let launch_error = "Dapp will start Voting at Timestamp "
1111
1212 let msg = "<h1>Your Vote Submitted Successfully!</h1><br>"
1313
1414 let AlreadyVotedError = "This Address Already participated for Voting in this Proposal."
1515
1616 let voteErr = "Voting is Over for this Dapp."
1717
1818 @Callable(i)
1919 func SetVotingTimeStamps (Proposal,Voting_Start_TimeStamp,Voting_End_TimeStamp) = {
2020 let StartTS = Voting_Start_TimeStamp
2121 let EndTS = Voting_End_TimeStamp
2222 let readtotalStakedA4A = getIntegerValue(A4AStakingDApp, "Staked_Amount")
2323 let QuorumValue = fraction(readtotalStakedA4A, 1, 3)
2424 let pubkey = toBase58String(i.caller.bytes)
2525 let Previoustotalproposals = match getInteger(this, "Total_Proposals") {
2626 case a: Int =>
2727 a
2828 case _ =>
2929 0
3030 }
3131 let totalproposals = (Previoustotalproposals + 1)
3232 if ((size(Proposal) > 5100))
3333 then throw("Subject Char Limits are Over. Reduce length less than 5100 Char.")
3434 else if ((i.caller != controller_address))
3535 then throw((("This Address is not Authorized. Only " + toString(controller_address)) + " is Authorized Address to Sign it."))
3636 else [StringEntry(("Proposal_Text_" + toString(totalproposals)), Proposal), IntegerEntry("Total_Proposals", totalproposals), StringEntry(("Proposer_" + toString(totalproposals)), pubkey), IntegerEntry(("Voting_Start_TimeStamp_" + toString(totalproposals)), StartTS), IntegerEntry(("Voting_End_TimeStamp_" + toString(totalproposals)), EndTS), IntegerEntry(("Quorum_" + toString(totalproposals)), QuorumValue), IntegerEntry(("Total_Votes_" + toString(totalproposals)), 0), IntegerEntry(("Total_No_" + toString(totalproposals)), 0), IntegerEntry(("Total_Yes_" + toString(totalproposals)), 0), StringEntry(("Quorum_Status_" + toString(totalproposals)), "Fail")]
3737 }
3838
3939
4040
4141 @Callable(i)
4242 func Yes (Porposal_ID) = {
4343 let VoteAst = "Yes"
4444 let StartTS = getIntegerValue(this, ("Voting_Start_TimeStamp_" + toString(Porposal_ID)))
4545 let EndTS = getIntegerValue(this, ("Voting_End_TimeStamp_" + toString(Porposal_ID)))
4646 let pubkey = toBase58String(i.caller.bytes)
4747 let readA4AStakingAmount = valueOrErrorMessage(getInteger(A4AStakingDApp, ("Deposit_Amount_Of_" + pubkey)), "Address not found in A4A Staking.")
4848 let readQuoraumValue = getIntegerValue(this, ("Quorum_" + toString(Porposal_ID)))
4949 let readTotalNoVotesValue = getIntegerValue(this, ("Total_No_" + toString(Porposal_ID)))
5050 let Previoustotalvotes = match getInteger(this, ("Total_Votes_" + toString(Porposal_ID))) {
5151 case a: Int =>
5252 a
5353 case _ =>
5454 0
5555 }
5656 let totalvotes = (Previoustotalvotes + readA4AStakingAmount)
5757 let FTVO = match getInteger(this, ((("Total_" + VoteAst) + "_") + toString(Porposal_ID))) {
5858 case a: Int =>
5959 a
6060 case _ =>
6161 0
6262 }
6363 let ATVO = (FTVO + readA4AStakingAmount)
6464 let PreviousUserCountforVoting = match getInteger(this, ((pubkey + "_") + toString(Porposal_ID))) {
6565 case a: Int =>
6666 a
6767 case _ =>
6868 0
6969 }
7070 let LatestUserCountforVoting = (PreviousUserCountforVoting + 1)
7171 if ((StartTS > lastBlock.timestamp))
7272 then throw((launch_error + toString(StartTS)))
7373 else if ((lastBlock.timestamp > EndTS))
7474 then throw(voteErr)
75- else if ((readQuoraumValue > totalvotes))
76- then [IntegerEntry(("Total_Votes_" + toString(Porposal_ID)), totalvotes), IntegerEntry(((("Total_" + VoteAst) + "_") + toString(Porposal_ID)), ATVO), IntegerEntry(((pubkey + "_") + toString(Porposal_ID)), LatestUserCountforVoting), StringEntry(("Quorum_Status_" + toString(Porposal_ID)), "Fail"), StringEntry("message", msg)]
77- else if ((totalvotes > readQuoraumValue))
78- then [IntegerEntry(("Total_Votes_" + toString(Porposal_ID)), totalvotes), IntegerEntry(((("Total_" + VoteAst) + "_") + toString(Porposal_ID)), ATVO), IntegerEntry(((pubkey + "_") + toString(Porposal_ID)), LatestUserCountforVoting), StringEntry(("Quorum_Status_" + toString(Porposal_ID)), "Pass"), StringEntry("message", msg)]
79- else nil
75+ else if (if ((readQuoraumValue > totalvotes))
76+ then (readTotalNoVotesValue > ATVO)
77+ else false)
78+ then [IntegerEntry(("Total_Votes_" + toString(Porposal_ID)), totalvotes), IntegerEntry(((("Total_" + VoteAst) + "_") + toString(Porposal_ID)), ATVO), IntegerEntry(((pubkey + "_") + toString(Porposal_ID)), LatestUserCountforVoting), StringEntry(("Quorum_Status_" + toString(Porposal_ID)), "Fail"), StringEntry(("Proposal_Status_" + toString(Porposal_ID)), "Rejected"), StringEntry("message", msg)]
79+ else if (if ((readQuoraumValue > totalvotes))
80+ then (ATVO > readTotalNoVotesValue)
81+ else false)
82+ then [IntegerEntry(("Total_Votes_" + toString(Porposal_ID)), totalvotes), IntegerEntry(((("Total_" + VoteAst) + "_") + toString(Porposal_ID)), ATVO), IntegerEntry(((pubkey + "_") + toString(Porposal_ID)), LatestUserCountforVoting), StringEntry(("Quorum_Status_" + toString(Porposal_ID)), "Fail"), StringEntry(("Proposal_Status_" + toString(Porposal_ID)), "Rejected"), StringEntry("message", msg)]
83+ else if (if ((totalvotes > readQuoraumValue))
84+ then (readTotalNoVotesValue > ATVO)
85+ else false)
86+ then [IntegerEntry(("Total_Votes_" + toString(Porposal_ID)), totalvotes), IntegerEntry(((("Total_" + VoteAst) + "_") + toString(Porposal_ID)), ATVO), IntegerEntry(((pubkey + "_") + toString(Porposal_ID)), LatestUserCountforVoting), StringEntry(("Quorum_Status_" + toString(Porposal_ID)), "Pass"), StringEntry(("Proposal_Status_" + toString(Porposal_ID)), "Pass-No"), StringEntry("message", msg)]
87+ else if (if ((totalvotes > readQuoraumValue))
88+ then (ATVO > readTotalNoVotesValue)
89+ else false)
90+ then [IntegerEntry(("Total_Votes_" + toString(Porposal_ID)), totalvotes), IntegerEntry(((("Total_" + VoteAst) + "_") + toString(Porposal_ID)), ATVO), IntegerEntry(((pubkey + "_") + toString(Porposal_ID)), LatestUserCountforVoting), StringEntry(("Quorum_Status_" + toString(Porposal_ID)), "Pass"), StringEntry(("Proposal_Status_" + toString(Porposal_ID)), "Pass-Yes"), StringEntry("message", msg)]
91+ else throw("Wrong Value Entered.")
8092 }
8193
8294
8395 @Verifier(tx)
8496 func verify () = sigVerify(tx.bodyBytes, tx.proofs[0], tx.senderPublicKey)
8597

github/deemru/w8io/169f3d6 
44.00 ms