tx · Wd8FXRmX9rqReh9BzJw3ETvVUDrTBPc2vbFgYDN6fiv 3N4vhLMZxRubzKWWZWU8hc2b6RMBnvZr3cE: -0.00100000 Waves 2024.09.24 00:26 [3296771] smart account 3N4vhLMZxRubzKWWZWU8hc2b6RMBnvZr3cE > SELF 0.00000000 Waves
{ "type": 13, "id": "Wd8FXRmX9rqReh9BzJw3ETvVUDrTBPc2vbFgYDN6fiv", "fee": 100000, "feeAssetId": null, "timestamp": 1727126866403, "version": 2, "chainId": 84, "sender": "3N4vhLMZxRubzKWWZWU8hc2b6RMBnvZr3cE", "senderPublicKey": "Go8eRBRcXBewAq9cx1nXjb4UhMwQRLBkSM1trk4hyiXu", "proofs": [ "3tq8WPegjev3QoTRB2JX1wJfMkDkKcTB24QF1U1mzxE8ejVz889Ls9XM4GMswUfUc62pUHu8LSPRBeSTz6QmrPFx" ], "script": "base64:BgIPCAISBgoECAgEARIDCgEIBAEQd3JpdGVDb25zdFN0cmluZwIDa2V5BXZhbHVlAwkBASEBCQEJaXNEZWZpbmVkAQkAnQgCBQR0aGlzBQNrZXkJAQtTdHJpbmdFbnRyeQIFA2tleQUFdmFsdWUJAAIBCQCsAgICFWFscmVhZHkgaW5pdGlhbGl6ZWQ6IAUDa2V5ABJjb25maWdBZGRyZXNzU3RvcmUCBmNvbmZpZwAGY29uZmlnCQETdmFsdWVPckVycm9yTWVzc2FnZQIJAKYIAQkBE3ZhbHVlT3JFcnJvck1lc3NhZ2UCCQCdCAIFBHRoaXMFEmNvbmZpZ0FkZHJlc3NTdG9yZQIhcmVzdWx0czogY29uZmlnIGFkZHJlc3Mgbm90IGZvdW5kAh9yZXN1bHRzOiBpbnZhbGlkIGNvbmZpZyBhZGRyZXNzAAZ2b3RpbmcJARN2YWx1ZU9yRXJyb3JNZXNzYWdlAgkApggBCQETdmFsdWVPckVycm9yTWVzc2FnZQIJAJ0IAgUGY29uZmlnAg9jb250cmFjdF92b3RpbmcCG3Jlc3VsdHM6IG5vIGNvbnRyYWN0X3ZvdGluZwIgcmVzdWx0czogaW52YWxpZCBjb250cmFjdF92b3RpbmcCAWkBCXNldFJlc3VsdAQHYWRkcmVzcwR0eElkB3N1Y2NlZWQPYnJvYWRjYXN0SGVpZ2h0AwkBAiE9AggFAWkGY2FsbGVyBQZ2b3RpbmcJAAIBAgZkZW5pZWQEBXN0b3JlCQCsAgIJAKwCAgkArAICAhlwcm9wb3NhbF9hbGxvd19icm9hZGNhc3RfBQdhZGRyZXNzAgFfBQR0eElkAwUHc3VjY2VlZAkAzAgCCQEMSW50ZWdlckVudHJ5AgUFc3RvcmUFD2Jyb2FkY2FzdEhlaWdodAUDbmlsCQDMCAIJAQtEZWxldGVFbnRyeQEFBXN0b3JlBQNuaWwBaQEEaW5pdAEEY29uZgkAzAgCCQEQd3JpdGVDb25zdFN0cmluZwIFEmNvbmZpZ0FkZHJlc3NTdG9yZQUEY29uZgUDbmlsAQJ0eAEGdmVyaWZ5AAQCaWQJANgEAQgFAnR4AmlkCQBnAgUGaGVpZ2h0CQERQGV4dHJOYXRpdmUoMTA1MCkCBQR0aGlzCQCsAgIJAKwCAgkArAICAhlwcm9wb3NhbF9hbGxvd19icm9hZGNhc3RfCQClCAEFBHRoaXMCAV8FAmlk88+Ewg==", "height": 3296771, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: none Next: none Full:
Old | New | Differences | |
---|---|---|---|
1 | - | # no script | |
1 | + | {-# STDLIB_VERSION 6 #-} | |
2 | + | {-# SCRIPT_TYPE ACCOUNT #-} | |
3 | + | {-# CONTENT_TYPE DAPP #-} | |
4 | + | func writeConstString (key,value) = if (!(isDefined(getString(this, key)))) | |
5 | + | then StringEntry(key, value) | |
6 | + | else throw(("already initialized: " + key)) | |
7 | + | ||
8 | + | ||
9 | + | let configAddressStore = "config" | |
10 | + | ||
11 | + | let config = valueOrErrorMessage(addressFromString(valueOrErrorMessage(getString(this, configAddressStore), "results: config address not found")), "results: invalid config address") | |
12 | + | ||
13 | + | let voting = valueOrErrorMessage(addressFromString(valueOrErrorMessage(getString(config, "contract_voting"), "results: no contract_voting")), "results: invalid contract_voting") | |
14 | + | ||
15 | + | @Callable(i) | |
16 | + | func setResult (address,txId,succeed,broadcastHeight) = if ((i.caller != voting)) | |
17 | + | then throw("denied") | |
18 | + | else { | |
19 | + | let store = ((("proposal_allow_broadcast_" + address) + "_") + txId) | |
20 | + | if (succeed) | |
21 | + | then [IntegerEntry(store, broadcastHeight)] | |
22 | + | else [DeleteEntry(store)] | |
23 | + | } | |
24 | + | ||
25 | + | ||
26 | + | ||
27 | + | @Callable(i) | |
28 | + | func init (conf) = [writeConstString(configAddressStore, conf)] | |
29 | + | ||
30 | + | ||
31 | + | @Verifier(tx) | |
32 | + | func verify () = { | |
33 | + | let id = toBase58String(tx.id) | |
34 | + | (height >= getIntegerValue(this, ((("proposal_allow_broadcast_" + toString(this)) + "_") + id))) | |
35 | + | } | |
36 | + |
github/deemru/w8io/026f985 12.28 ms ◑