Modify ↓
#12121 closed defect (fixed)
Does not work with checkbox type fields
Reported by: | Owned by: | Ryan J Ollos | |
---|---|---|---|
Priority: | normal | Component: | TicketValidatorPlugin |
Severity: | normal | Keywords: | |
Cc: | Trac Release: | 1.0 |
Description
This plugin (which is really nice btw) doesn't work with checkbox type fields. The validator triggers on a field being empty or having zero length. Since a checkbox field has a value of 0 by default, it not being checked isn't considered as "missing", so even if set as required the validator will not stop the ticket from proceeding if the box is unchecked.
Adding a check for "equals zero" for checkbox type fields in the _is_empty function will probably fix it.
Attachments (0)
Change History (5)
comment:1 Changed 10 years ago by
Owner: | changed from Max Stewart to Ryan J Ollos |
---|---|
Status: | new → accepted |
comment:2 Changed 10 years ago by
comment:3 Changed 10 years ago by
Resolution: | → fixed |
---|---|
Status: | accepted → closed |
Thanks, let's call it fixed in [14383] then.
comment:4 Changed 10 years ago by
I'd have to agree, it is fixed. I can provide screen shots if required.
comment:5 Changed 10 years ago by
After I updated to that version, it worked for me as well - thanks guys!
Note: See
TracTickets for help on using
tickets.
I have tested the current version, in my testing and production environments, having select, check boxes, date/time fields in various states required. All appear to be working correct with the latest changes.