When a user adds a write-in option to a ranking poll, the "write_in_weight" field is not updated. This results in the write-in vote always being ranked first in the user's selection of options.

Furthermore, when the user enters text in the write-in field without adding it to the table, and also adds at least one other vote to the table, the write-in and the selected option both have an identical rank of 1.

The attached patch fixes both related issues, by properly setting the write-in's weight field, and by ensuring each vote has a unique rank.

CommentFileSizeAuthor
advpoll-update-write-in-weight.patch1.36 KBsmokris

Comments

tripper54’s picture

Issue summary: View changes
Priority: Critical » Major

  • tripper54 committed 24b1546 on 7.x-3.x authored by smokris
    Issue #1936952 by smokris: Weight isn't set for write-in votes
    
tripper54’s picture

Status: Needs review » Fixed

Thanks, committed!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.