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

Added option to get unique votes based on userid instead of ip-address #44

Open
wants to merge 1 commit into
base: release/v1.3.2-pl
Choose a base branch
from

Conversation

bvandorp
Copy link

Usage: [[!Polls? &id=1 &uniqueBy=user ]] or [[!PollsLatest? &uniqueBy=user]]

  • fixed usage of undefined object $latest in Polls snippet, change to $poll
  • added field 'user' to polls_answers table
  • added userid to logging (defaults to 0 when not logged in)
  • added option for Polls snippet and rewrote the check part
  • added option for PollsLatest snippet and rewrote the check part
  • added user to logVote() in modpollanswer.class.php
  • rewrote hasVoted() in modpollanswer.class.php to handle with the option
  • rewrote hasVoted() in modpollquestion.class.php to handle with the option

Usage: [[!Polls? &id=`1` &uniqueBy=`user` ]] or [[!PollsLatest? &uniqueBy=`user`]]

- added field 'user' to polls_answers table
- added userid to logging (defaults to 0 when not logged in)
- added option for Polls snippet and rewrote the check part
- added option for PollsLatest snippet and rewrote the check part
- added user to logVote() in modpollanswer.class.php
- rewrote hasVoted() in modpollanswer.class.php to handle with the option
- rewrote hasVoted() in modpollquestion.class.php to handle with the option
@solidusite solidusite changed the base branch from master to release/v1.3.2-pl September 20, 2017 08:32
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.

1 participant