Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding changes related to voting #77

Closed

Conversation

FaezZangariya
Copy link
Collaborator

I added a new model called Poll to help with implementing the fucntionality of voting on chores and made small changes to the existing Vote model , i will also be pushing the front end related to voting later today, i need a user to be logged in for me to check if he already voted on a specific chore , also i need to create a new Vote specefic to the choice of the user logged in everytime a user votes with yes or no , other than that for this to function we need to create a new poll everytime we create a new chore, no tests yet, i need the signup and login functionalitys to be working then i will add the tests.

Signed-off-by: faezzangariya faezzangariyacs@gmail.com

I added a new model called Poll to help with implementing the
fucntionality of voting on chores and made small changes to the existing
Vote model , i will also be pushing the front end related to voting
later today, i need a user to be logged in for me to check if he already voted on a
specific chore , also i need to create a new Vote specefic to the choice of the
user logged in everytime a user votes with yes or no , other than that for this to
function we need to create a new poll everytime we create a new chore,
no tests yet, i need the signup and login functionalitys to be working
then i will add the tests.

Signed-off-by: faezzangariya <faezzangariyacs@gmail.com>
Copy link
Collaborator

@RonTuretzky RonTuretzky left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand the utility this provides

@FaezZangariya
Copy link
Collaborator Author

I don't understand the utility this provides

i just added that model for better presentation of the voting on the front end , cause we need to present a single form of voting for each indivisual chore , for each chore we would have one poll for voting where every user votes, but for every chore there is multiple votes , i couldn't find a way to collect votes from multiple users on one chore without adding the new model , every time we create a new chore we need to also create a new poll witch manages and collects votes from all users per chore.
(the poll model is more for the visual side of things and the collection of user vote inputs)

@RonTuretzky
Copy link
Collaborator

I don't understand the utility this provides

i just added that model for better presentation of the voting on the front end , cause we need to present a single form of voting for each indivisual chore , for each chore we would have one poll for voting where every user votes, but for every chore there is multiple votes , i couldn't find a way to collect votes from multiple users on one chore without adding the new model , every time we create a new chore we need to also create a new poll witch manages and collects votes from all users per chore. (the poll model is more for the visual side of things and the collection of user vote inputs)

Why can't we attach to each chore a "Yes" & "No" button, and when the user clicks on it , it creates a new Vote instance?
If there's already a vote in the db then it won't show the buttons.
When separate users use the buttons, it creates a Vote instance with their own unique user_id, so multiple users can vote

What visual utility does this model provide that we can't supply with the Vote model?

@FaezZangariya
Copy link
Collaborator Author

I don't understand the utility this provides

i just added that model for better presentation of the voting on the front end , cause we need to present a single form of voting for each indivisual chore , for each chore we would have one poll for voting where every user votes, but for every chore there is multiple votes , i couldn't find a way to collect votes from multiple users on one chore without adding the new model , every time we create a new chore we need to also create a new poll witch manages and collects votes from all users per chore. (the poll model is more for the visual side of things and the collection of user vote inputs)

this way we can also add a feauture of adding custom polls where the title and the choices are customizable

@RonTuretzky
Copy link
Collaborator

I don't understand the utility this provides

i just added that model for better presentation of the voting on the front end , cause we need to present a single form of voting for each indivisual chore , for each chore we would have one poll for voting where every user votes, but for every chore there is multiple votes , i couldn't find a way to collect votes from multiple users on one chore without adding the new model , every time we create a new chore we need to also create a new poll witch manages and collects votes from all users per chore. (the poll model is more for the visual side of things and the collection of user vote inputs)

this way we can also add a feauture of adding custom polls where the title and the choices are customizable

I see ... I think this is more "nice to have" then "must have" and maybe if we can implement it later we should circle back to it, and for now to limit the functionality to "Yes" & "No", what do you think?

@FaezZangariya
Copy link
Collaborator Author

I don't understand the utility this provides

i just added that model for better presentation of the voting on the front end , cause we need to present a single form of voting for each indivisual chore , for each chore we would have one poll for voting where every user votes, but for every chore there is multiple votes , i couldn't find a way to collect votes from multiple users on one chore without adding the new model , every time we create a new chore we need to also create a new poll witch manages and collects votes from all users per chore. (the poll model is more for the visual side of things and the collection of user vote inputs)

Why can't we attach to each chore a "Yes" & "No" button, and when the user clicks on it , it creates a new Vote instance? If there's already a vote in the db then it won't show the buttons. When separate users use the buttons, it creates a Vote instance with their own unique user_id, so multiple users can vote

What visual utility does this model provide that we can't supply with the Vote model?

we could do it like you said , but i am not the best with the frontend side of things , i could setup the background your way but Elias would have to continue with the frontend

@RonTuretzky
Copy link
Collaborator

I don't understand the utility this provides

i just added that model for better presentation of the voting on the front end , cause we need to present a single form of voting for each indivisual chore , for each chore we would have one poll for voting where every user votes, but for every chore there is multiple votes , i couldn't find a way to collect votes from multiple users on one chore without adding the new model , every time we create a new chore we need to also create a new poll witch manages and collects votes from all users per chore. (the poll model is more for the visual side of things and the collection of user vote inputs)

Why can't we attach to each chore a "Yes" & "No" button, and when the user clicks on it , it creates a new Vote instance? If there's already a vote in the db then it won't show the buttons. When separate users use the buttons, it creates a Vote instance with their own unique user_id, so multiple users can vote
What visual utility does this model provide that we can't supply with the Vote model?

we could do it like you said , but i am not the best with the frontend side of things , i could setup the background your way but Elias would have to continue with the frontend

Sounds good to me!

@FaezZangariya
Copy link
Collaborator Author

I don't understand the utility this provides

i just added that model for better presentation of the voting on the front end , cause we need to present a single form of voting for each indivisual chore , for each chore we would have one poll for voting where every user votes, but for every chore there is multiple votes , i couldn't find a way to collect votes from multiple users on one chore without adding the new model , every time we create a new chore we need to also create a new poll witch manages and collects votes from all users per chore. (the poll model is more for the visual side of things and the collection of user vote inputs)

Why can't we attach to each chore a "Yes" & "No" button, and when the user clicks on it , it creates a new Vote instance? If there's already a vote in the db then it won't show the buttons. When separate users use the buttons, it creates a Vote instance with their own unique user_id, so multiple users can vote
What visual utility does this model provide that we can't supply with the Vote model?

we could do it like you said , but i am not the best with the frontend side of things , i could setup the background your way but Elias would have to continue with the frontend

Sounds good to me!

Ok! On it

@FaezZangariya
Copy link
Collaborator Author

Closing Pr for now , We decided to go a diffrent route with the voting implementation.

@FaezZangariya FaezZangariya mentioned this pull request Jan 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants