tx · 99UJAjuezNNWKZnGLybW31mzhh1eCSdYyBfsiooCFb6w

3MzkbT7RKSGjgYDEYC8q9zeTuWRtio7xrPs:  -0.00200000 Waves

2024.10.03 22:30 [3311092] smart account 3MzkbT7RKSGjgYDEYC8q9zeTuWRtio7xrPs > SELF 0.00000000 Waves

{ "type": 13, "id": "99UJAjuezNNWKZnGLybW31mzhh1eCSdYyBfsiooCFb6w", "fee": 200000, "feeAssetId": null, "timestamp": 1727983829666, "version": 2, "chainId": 84, "sender": "3MzkbT7RKSGjgYDEYC8q9zeTuWRtio7xrPs", "senderPublicKey": "445GawK5zD2cV4H68HQntVM6te2YU5GMd3X6jFUX5VHG", "proofs": [ "4kuTLZkBR8x7PYfhVQdtXPzBM4GgUcZ8iZPzHv34e1JPeXybjEpFHkafZT8JXo2SqrFDFerAxDGABBYDRYEfYwyh" ], "script": "base64:AAIFAAAAAAAAABgIAhIECgIIARIECgIIARIDCgEIEgMKAQgAAAAFAQAAABB3cml0ZUNvbnN0U3RyaW5nAAAAAgAAAANrZXkAAAAFdmFsdWUDCQEAAAABIQAAAAEJAQAAAAlpc0RlZmluZWQAAAABCQAEHQAAAAIFAAAABHRoaXMFAAAAA2tleQkBAAAAC1N0cmluZ0VudHJ5AAAAAgUAAAADa2V5BQAAAAV2YWx1ZQkAAAIAAAABCQABLAAAAAICAAAAFWFscmVhZHkgaW5pdGlhbGl6ZWQ6IAUAAAADa2V5AQAAAAh3cml0ZUludAAAAAIAAAADa2V5AAAABXZhbHVlAwkAAGYAAAACAAAAAAAAAAAABQAAAAV2YWx1ZQkAAAIAAAABCQABLAAAAAIJAAEsAAAAAgkAASwAAAACAgAAABd3cml0aW5nIG5lZ2F0aXZlIHZhbHVlIAkAAaQAAAABBQAAAAV2YWx1ZQIAAAAJIGZvciBrZXkgBQAAAANrZXkJAQAAAAxJbnRlZ2VyRW50cnkAAAACBQAAAANrZXkFAAAABXZhbHVlAAAAABJjb25maWdBZGRyZXNzU3RvcmUCAAAABmNvbm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AgkBAAAAC0RlbGV0ZUVudHJ5AAAAAQUAAAADa2V5BQAAAANuaWwAAAABaQEAAAAEaW5pdAAAAAEAAAAGY29uZmlnCQAETAAAAAIJAQAAABB3cml0ZUNvbnN0U3RyaW5nAAAAAgUAAAASY29uZmlnQWRkcmVzc1N0b3JlBQAAAAZjb25maWcFAAAAA25pbAAAAAB+ZKjp", "height": 3311092, "applicationStatus": "succeeded", "spentComplexity": 0 } View: original | compacted Prev: none Next: none Full:
OldNewDifferences
1-# no script
1+{-# STDLIB_VERSION 5 #-}
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+func writeInt (key,value) = if ((0 > value))
10+ then throw(((("writing negative value " + toString(value)) + " for key ") + key))
11+ else IntegerEntry(key, value)
12+
13+
14+let configAddressStore = "config"
15+
16+let configAddress = valueOrErrorMessage(addressFromString(valueOrErrorMessage(getString(this, configAddressStore), "userdata: no config")), "userdata: invalid config address")
17+
18+let voting = valueOrErrorMessage(addressFromString(valueOrErrorMessage(getString(configAddress, "contract_voting"), "no contract_voting")), "invalid contract_voting")
19+
20+@Callable(i)
21+func write (key,value) = if ((i.caller != voting))
22+ then throw("denied")
23+ else [IntegerEntry(key, value)]
24+
25+
26+
27+@Callable(i)
28+func changeBy (key,delta) = if ((i.caller != voting))
29+ then throw("denied")
30+ else [writeInt(key, (valueOrElse(getInteger(key), 0) + delta))]
31+
32+
33+
34+@Callable(i)
35+func delete (key) = if ((i.caller != voting))
36+ then throw("denied")
37+ else [DeleteEntry(key)]
38+
39+
40+
41+@Callable(i)
42+func init (config) = [writeConstString(configAddressStore, config)]
43+
44+

github/deemru/w8io/026f985 
10.92 ms