For the complete documentation index, see llms.txt. This page is also available as Markdown.

EcoPotVoting

This contract is creating and managing of the EcoPot project and exercising voting rights for the EcoPot project. KSP staking users vote for the EcoPot project they want and receive tokens according to their stake.

Address

CreateEcoPot

event CreateEcoPot(address operator, address ecoPot, address token, string name);
  • Event log of EcoPot created

  • Parameters

    • operator : EcoPotOperator address

    • ecoPot : EcoPot address

    • token : Token address received by user

    • name : EcoPot Project name

RemoveEcoPot

event RemoveEcoPot(address ecoPot);
  • Event that occurs when EcoPot is removed

ChangeEcoPotAvailable

event ChangeEcoPotAvailable(address ecoPot, bool b);
  • Event that occurs when the status is changed

AddVoting

event AddVoting(address user, address ecopot, uint amount);
  • Event log of voting vKSP for EcoPot

  • Parameters

    • user : User address

    • ecopot : EcoPot address

    • amount : Vote vKSP amount

RemoveVoting

  • Event log of remove voting vKSP for EcoPot

  • Parameters

    • user : User address

    • ecopot : EcoPot address

    • amount : Unote vKSP amount

Read-Only Functions

ecoPotCount

  • Number of EcoPot

MAX_VOTING_POT_COUNT

  • Maximum number of EcoPots where users can vote

ecoPotList

  • mapping(uint => address)

  • EcoPot addresses

ecoPotExist

  • mapping(address => bool)

  • Return if the address is EcoPot address

potTotalVotedAmount

  • Total voted number of EcoPot

userVotingPotCount

  • mapping(address => uint)

  • Number of votes each user voted for EcoPot

userVotingPotAddress

  • EcoPot addresses voted by each user

userVotingPotAmount

  • EcoPot voted amount by each user

State-Changing Functions

addVoting

  • Method to voting vKSP for EcoPot

  • The amount can be entered in integer units

removeVoting

  • Method to remove voting vKSP for Ecopot

  • The amount can be entered in integer units within the voting limit

removeAllVoting

  • Method of remove total vote Ecopot

claimReward

  • Method of vote Ecopot’s reward

claimRewardAll

  • Method of all vote Ecopot’s reward