Commit graph

13 commits

Author SHA1 Message Date
Leonard Lyubich
c3efe152d6 [#42] Share Vote/RemoteVotes between contracts
Replace vote/remoteVotes functions from all contracts (except alphabet) to
common package. Additionally replace setSerialized and bytesEqual. Create
InitVote function and use it in NeoFS and Netmap contracts.

Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2021-02-04 10:31:24 +03:00
Leonard Lyubich
f9f2a03078 [#42] Share ballot structure between contracts
Create common package. Define Ballot struct in common package. Use new type
in all contracts with ballots.

Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2021-02-04 10:31:24 +03:00
Alex Vanin
c6fd4dc77c [#23] *: Update script hashes of native contracts
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-12-29 14:15:26 +03:00
Alex Vanin
1dcfb59a1f [#23] alphabet: Use single contract instead of template
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-12-29 14:15:26 +03:00
Alex Vanin
5fc9ed999d [#23] *: Update script hashes of native contracts
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-12-29 14:15:26 +03:00
Alex Vanin
bd45e50480 [#23] alphabet: Add OnPayment method
Without OnPayment method alphabet contracts won't be able
to receive NEO and produce GAS.

Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-12-29 14:15:26 +03:00
Alex Vanin
29f2f0ef17 [#23] *: Support NEP-17 in native asset transfers
Now `transfer()` requires 4 arguments.

Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-12-29 14:15:26 +03:00
Alex Vanin
189a83d9d6 [#23] *: Replace engine.AppCall with contract.Call 2020-12-29 14:15:26 +03:00
Alex Vanin
a8d55d9166 [#19] alphabet: Check epoch value in Vote method
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-12-09 10:50:45 +03:00
Alex Vanin
24b7bc5c77 [#19] alphabet: Add signature collection in Vote method
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-12-09 10:50:45 +03:00
Alex Vanin
2a509ebbee [#19] alphabet: Add log on voting
Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-12-09 10:50:45 +03:00
Alex Vanin
f8190f7a91 [#19] alphabet: Add vote method
Alphabet contracts are holders of NEO token in sidechain.
Inner ring nodes control sidechain validators list through
voting of alphabet contracts.

Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-12-09 10:50:45 +03:00
Alex Vanin
bf391b57dd [#18] Add sidechain contracts
Sidechain contracts include alphabet contracts for governance
and audit, balance, container, neofsid, netmap, reputation
contracts.

Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2020-10-27 17:33:56 +03:00