Ticket #1986: admin_list_bug.patch

File admin_list_bug.patch, 652 bytes (added by rob@…, 18 years ago)

the patch :)

  • admin_list.py

     
    154154            # FloatFields are special: Zero-pad the decimals.
    155155            elif isinstance(f, models.FloatField):
    156156                if field_val is not None:
    157                     result_repr = ('%%.%sf' % f.decimal_places) % field_val
     157                    result_repr = ('%%.%sf' % f.decimal_places) % float(field_val)
    158158                else:
    159159                    result_repr = EMPTY_CHANGELIST_VALUE
    160160            # Fields with choices are special: Use the representation
Back to Top