tx · FJN1tPN1GjZNG3Ny5jc7GKVhsDkqWcsJu3FEVoX3yhMq

3NBkfbAAqPqkY4d3LK36hdDUpDXViEAHfDE:  -0.01400000 Waves

2019.09.08 16:54 [667183] smart account 3NBkfbAAqPqkY4d3LK36hdDUpDXViEAHfDE > SELF 0.00000000 Waves

{ "type": 13, "id": "FJN1tPN1GjZNG3Ny5jc7GKVhsDkqWcsJu3FEVoX3yhMq", "fee": 1400000, "feeAssetId": null, "timestamp": 1567950876419, "version": 1, "sender": "3NBkfbAAqPqkY4d3LK36hdDUpDXViEAHfDE", "senderPublicKey": "FUCE44aWkQuFEKpfWRe3zoW8pGN2caDm1vqoK55FTnLP", "proofs": [ "2t9aVc9XeMSgfDK9YvyYHhgeorfZykBwELeM5R1z6LhnEzFsgutRce94bR4T8at58iQpYZDyQiJMQAAzmvqXvYtt" ], "script": "base64:AAIDAAAAAAAAAAAAAAACAQAAABR2b3RlcklzQWxsb3dlZFRvVm90ZQAAAAEAAAAOdm90ZXJQdWJsaWNLZXkEAAAADGF1ZGl0b3Ixb3BlbgEAAAAgTOH7xS01EPXuKJWTnxxjNR2ezIws9jQx04+962nHjyQEAAAADGZhY3Rvcnkxb3BlbgEAAAAgmKQJPfQtwWEG3Uomcd12TJmvXUIMK+zQKCau0mej4h8DAwkBAAAAAiE9AAAAAgUAAAAOdm90ZXJQdWJsaWNLZXkFAAAADGF1ZGl0b3Ixb3BlbgkBAAAAAiE9AAAAAgUAAAAOdm90ZXJQdWJsaWNLZXkFAAAADGZhY3Rvcnkxb3BlbgcHBgEAAAAJaXNBdWRpdG9yAAAAAQAAAA52b3RlclB1YmxpY0tleQQAAAAMYXVkaXRvcjFvcGVuAQAAACBM4fvFLTUQ9e4olZOfHGM1HZ7MjCz2NDHTj73racePJAMJAQAAAAIhPQAAAAIFAAAADnZvdGVyUHVibGljS2V5BQAAAAxhdWRpdG9yMW9wZW4HBgAAAAIAAAABaQEAAAAEdm90ZQAAAAEAAAAHdGhlVm90ZQMJA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TQvtCx0LDQstC70Y/RgtGMINC00LDQvdC90YvQtSwg0LLRiyDQvdC1INC30LDQutCw0LfRh9C40LoJAQAAAAhXcml0ZVNldAAAAAEJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAICAAAAB2F1ZGl0b3IFAAAADGF1ZGl0b3Ixb3BlbgkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgIAAAAHZmFjdG9yeQUAAAAMZmFjdG9yeTFvcGVuBQAAAANuaWwAAAAAIvPqhg==", "chainId": 84, "height": 667183, "spentComplexity": 0 } View: original | compacted Prev: 4sGdn9ccxzz3DX2awKU7kZ7dkNr5mshxTfyzXSfeMH4K Next: none Full:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 func voterIsAllowedToVote (voterPublicKey) = {
55 let auditor1open = base58'6B7r4pWd3dB79ojogTFvQ2tspsav6gsL4iWqzsRG2rhR'
66 let factory1open = base58'BGr3aRnHxWYKViZ9AKkqE7CdczJtRGk2vCzbGF5mX7dp'
77 if (if ((voterPublicKey != auditor1open))
88 then (voterPublicKey != factory1open)
99 else false)
1010 then false
1111 else true
1212 }
1313
1414
1515 func isAuditor (voterPublicKey) = {
1616 let auditor1open = base58'6B7r4pWd3dB79ojogTFvQ2tspsav6gsL4iWqzsRG2rhR'
1717 if ((voterPublicKey != auditor1open))
1818 then false
1919 else true
2020 }
2121
2222
2323 @Callable(i)
2424 func vote (theVote) = if (!(voterIsAllowedToVote(i.callerPublicKey)))
2525 then throw("У вас нет прав доступа")
2626 else {
2727 let dataFromStorage = getInteger(this, toBase58String(i.callerPublicKey))
2828 let getAuditor = getStringValue(this, "Auditor")
2929 let getFactory = getStringValue(this, "Factory")
3030 if (isDefined(dataFromStorage))
3131 then throw("Ваша подпись уже поставлена")
3232 else WriteSet([DataEntry(toBase58String(i.callerPublicKey), theVote)])
3333 }
3434
3535
3636
3737 @Callable(i)
3838 func record (theInteger) = {
3939 let auditor1open = base58'6B7r4pWd3dB79ojogTFvQ2tspsav6gsL4iWqzsRG2rhR'
4040 let factory1open = base58'BGr3aRnHxWYKViZ9AKkqE7CdczJtRGk2vCzbGF5mX7dp'
4141 let myOpen = base58'FUCE44aWkQuFEKpfWRe3zoW8pGN2caDm1vqoK55FTnLP'
4242 if ((i.callerPublicKey != myOpen))
4343 then throw("Вы не можете добавлять данные, вы не заказчик")
4444 else WriteSet([DataEntry("auditor", auditor1open), DataEntry("factory", factory1open)])
4545 }
4646
4747

github/deemru/w8io/169f3d6 
30.95 ms