Novusphere / discussions-vue

A Vue.js implementation of Discussions using the novusphere-js API - https://discussions.app
MIT License
12 stars 8 forks source link

Staking 2.0 for Discussions 3.0 #212

Open Novusphere opened 4 years ago

Novusphere commented 4 years ago

Implement a smart contract for staking 2.0 that allows the following:

Users via a public key are able to deposit funds into the smart contract. A user can then commit to locking funds in the contract for a given amount of days; this is called a vault. A user can have multiple vaults. A user can renew a vault to expire at a later date then it is currently expiring. The weight of a vault is the amount of tokens it holds and the remaining days until the vault expires.

A user can withdraw funds from a vault that has expired.

The contract has a function "claim" which can be called by anyone every 24 hours. Assumable, the Novusphere Foundation will call this function every 24h so the community doesn't need to. The claim function iterates through all vaults and pays from a daily subsidy relative to each vaults weight.

xia256 commented 3 years ago

Updating this issue:

Smart contract has been deployed to main net a few weeks ago and testing is in progress. Internal beta testing is at a near acceptable point to start closed-beta testing with a few users.