Ticket #2300: django_forms__init__.diff
File django_forms__init__.diff, 1.1 KB (added by , 18 years ago) |
---|
-
django/forms/__init__.py
53 53 54 54 def get_validation_errors(self, new_data): 55 55 "Returns dictionary mapping field_names to error-message lists" 56 self.prepare(new_data) 56 57 errors = {} 57 58 for field in self.fields: 58 59 errors.update(field.get_validation_errors(new_data)) … … 636 637 if str(value) in str_data_list: 637 638 checked_html = ' checked="checked"' 638 639 field_name = '%s%s' % (self.field_name, value) 639 output.append('<li><input type="checkbox" id="%s" class="v%s" name="%s"%s /> <label for="%s">%s</label></li>' % \640 output.append('<li><input type="checkbox" id="%s" class="v%s" name="%s"%s value="on" /> <label for="%s">%s</label></li>' % \ 640 641 (self.get_id() + value , self.__class__.__name__, field_name, checked_html, 641 642 self.get_id() + value, choice)) 642 643 output.append('</ul>')