old_dapp icon indicating copy to clipboard operation
old_dapp copied to clipboard

implement getter for voting, delegating and revoking data and populate graph library

Open virgile-dev opened this issue 7 years ago • 12 comments

For ballot X:

  • [x] (1) getters for all voters to populate possible "representatives" list
  • [x] (2) getters to get delegation data
  • [x] (3) getters to get voting data
  • [x] (4) getters to get revoking data
  • [ ] (5) implement third graph area proposed by @AlexJupiter

Params for delegate() function are : delegate(address from, address representative) Params for vote() function are : vote(address voter, uint ballotId, uint voteOption)

virgile-dev avatar Apr 22 '18 11:04 virgile-dev

Voting graph bellow ballot: capture d ecran 2018-04-22 a 13 46 54

virgile-dev avatar Apr 22 '18 11:04 virgile-dev

Guys one doubt I'm having about this yes / no delegate graph is how we make it work when people have delegated their votes but the delegates haven't voted yet. How do you show that in the current setting ? @AlexJupiter @aecc

virgile-dev avatar Apr 23 '18 17:04 virgile-dev

In that case it wouldn't have a link between the YES and the repreentative. I think it would look ok and would be easy to understand. We can plot an example once that's implemented to see how the library will handle it

aecc avatar Apr 23 '18 21:04 aecc

@virgile-dev Oh good spot. I actually think a third section called “swing voters” or something could be interesting. Imagine this pool of delegates, all who have amasassed a tonne of votes, but haven’t yet decided which way they will vote. It would be a super cool indication of how the “swing voters” could tip the ballot right at the end.

If that’s not clear I’ll try to upload a sketch tomorrow!

AlexJupiter avatar Apr 23 '18 21:04 AlexJupiter

So this is the sketch to explain my comment above: image

I added a Playground section in the inVision Freehand document that we have been working on, so people can iterate on this if they so wish.

To explain in more detail:

  • I have added a "Unused delegate section". This will show all delegations to delegates, who have not yet decided if they are going to vote yes or no
  • Obama has 5 unused delegations and Aragon has 1 unused delegation.
  • When Obama and Aragon vote they would vote with 6 and 2 votes respectively as they will also add their own individual vote (this could be represented more clearly in the sketch I will admit).

This is considering, that when a user delegates, they do not determine how the delegate can be used. I think this is the key difference in this proposal in contrast to what @aecc proposes above.

AlexJupiter avatar Apr 24 '18 11:04 AlexJupiter

aha now I understand what @virgile-dev meant, my bad. It looks super to me :), the only comment I have is that I would place the YES/NO before the "unused". YES/NO seems more informative to be displayed first.

aecc avatar Apr 24 '18 16:04 aecc

working in "getters for all voters to populate possible "representatives" list"

aecc avatar May 02 '18 16:05 aecc

Working on “ getters to get delegation data"

aecc avatar May 02 '18 20:05 aecc

Working on (3)

aecc avatar May 03 '18 19:05 aecc

Working on (4)

aecc avatar May 13 '18 21:05 aecc

@aecc are you working on (5)?

AlexJupiter avatar May 29 '18 17:05 AlexJupiter

Hey @AlexJupiter , not at the moment. Probably up next. I'll remove it from In progress meanwhile

aecc avatar May 29 '18 19:05 aecc