@@ -16,7 +16,7 @@ contract Convenience is Ownable {
1616 /// @notice Staking pool of the DAO
1717 IApi3PoolExtended public immutable api3Pool;
1818 /// @notice List of ERC20 addresses that will be displayed in the DAO
19- /// treasury
19+ /// treasury. The ETH balance will also be displayed by default.
2020 /// @dev These are set by the owner of this contract
2121 address [] public erc20Addresses;
2222 /// @notice Links to the discussion venues for each vote
@@ -74,6 +74,26 @@ contract Convenience is Ownable {
7474
7575 /// @notice Used by the DAO dashboard client to retrieve user staking data
7676 /// @param userAddress User address
77+ /// @return apr Staking reward APR
78+ /// @return api3Supply API3 total supply
79+ /// @return totalStake Total amount staked at the pool
80+ /// @return totalShares Total pool shares (also represents total voting
81+ /// power)
82+ /// @return stakeTarget Pool stake target in percentages
83+ /// @return userApi3Balance User API3 balance
84+ /// @return userStaked Amount of staked tokens the user has at the pool
85+ /// @return userUnstaked Amount of non-staked tokens the user has at the
86+ /// pool
87+ /// @return userVesting Amount of tokens not yet vested to the user (it is
88+ /// not withdrawable, similar to `userLocked`)
89+ /// @return userUnstakeAmount Amount of tokens the user scheduled to
90+ /// unstake
91+ /// @return userUnstakeShares Amount of shares the user gave up to schedule
92+ /// the unstaking
93+ /// @return userUnstakeScheduledFor Time when the scheduled unstake will
94+ /// mature
95+ /// @return userLocked Amount of rewards the user has received that are not
96+ /// withdrawable yet
7797 function getUserStakingData (address userAddress )
7898 external
7999 view
@@ -114,7 +134,24 @@ contract Convenience is Ownable {
114134
115135 /// @notice Used by the DAO dashboard client to retrieve the treasury and
116136 /// user delegation data
137+ /// @dev In addition to the ERC20 tokens, it returns the ETH balances of
138+ /// the treasuries
117139 /// @param userAddress User address
140+ /// @return names ERC20 (+ Ethereum) names
141+ /// @return symbols ERC20 (+ Ethereum) symbols
142+ /// @return decimals ERC20 (+ Ethereum) decimals
143+ /// @return balancesOfPrimaryAgent ERC20 (+ Ethereum) balances of the
144+ /// primary agent
145+ /// @return balancesOfSecondaryAgent ERC20 (+ Ethereum) balances of the
146+ /// secondary agent
147+ /// @return proposalVotingPowerThreshold Proposal voting power threshold in
148+ /// percentages
149+ /// @return userVotingPower Voting power of the user, including delegations
150+ /// @return delegatedToUser Voting power delegated to user
151+ /// @return delegate Address that the user has delegated to
152+ /// @return lastDelegationUpdateTimestamp When the user has last updated
153+ /// their delegation
154+ /// @return lastProposalTimestamp When the user has last made a proposal
118155 function getTreasuryAndUserDelegationData (address userAddress )
119156 external
120157 view
@@ -171,6 +208,17 @@ contract Convenience is Ownable {
171208 /// @param votingAppType Enumerated voting app type (primary or secondary)
172209 /// @param userAddress User address
173210 /// @param voteIds Array of vote IDs for which data will be retrieved
211+ /// @return startDate Start date of the vote
212+ /// @return supportRequired Support required for the vote to pass in
213+ /// percentages
214+ /// @return minAcceptQuorum Minimum acceptance quorum required for the vote
215+ /// to pass in percentages
216+ /// @return votingPower Total voting power at the time the vote was created
217+ /// @return script The EVMScript that will be run if the vote passes
218+ /// @return userVotingPowerAt User's voting power at the time the vote was
219+ /// created
220+ /// @return discussionUrl Discussion URL set for the vote by the contract
221+ /// owner
174222 function getStaticVoteData (
175223 VotingAppType votingAppType ,
176224 address userAddress ,
@@ -230,6 +278,13 @@ contract Convenience is Ownable {
230278 /// @param votingAppType Enumerated voting app type (primary or secondary)
231279 /// @param userAddress User address
232280 /// @param voteIds Array of vote IDs for which data will be retrieved
281+ /// @return executed If the vote has been executed
282+ /// @return yea Total voting power voted for "For"
283+ /// @return nay Total voting power voted for "Against"
284+ /// @return voterState Vote cast by the user
285+ /// @return delegateAt Address the user has delegated to at the time the
286+ /// vote was created
287+ /// @return delegateState Vote cast by the delegate of the user
233288 function getDynamicVoteData (
234289 VotingAppType votingAppType ,
235290 address userAddress ,
@@ -268,7 +323,7 @@ contract Convenience is Ownable {
268323 , // open
269324 executed[i],
270325 , // startDate
271- snapshotBlock ,
326+ snapshotBlock,
272327 , // supportRequired
273328 , // minAcceptQuorum
274329 yea[i],
0 commit comments