PetrDlouhy / django-related-admin

Allow foreign key attributes in list_display with '__'
BSD 3-Clause "New" or "Revised" License
69 stars 13 forks source link

Use value as first argument #10

Closed leibowitz closed 6 years ago

leibowitz commented 6 years ago

Choice fields (TextField or CharField with choices argument set) always have their value in the list displayed as empty.

This fixes it. And doesn't seem to break anything else for me, but please make sure I'm not doing something stupid before merging please!

FYI, the change was introduced here

coveralls commented 6 years ago

Coverage Status

Coverage decreased (-100.0%) to 0.0% when pulling 249ca2626cb6936547ad8a4bc2096abc4e308f98 on wintercircle:fix_choices into 720e3c42d5b449694130843cb92c4e7ac7228b6a on PetrDlouhy:master.

PetrDlouhy commented 6 years ago

@leibowitz Great, thank you very much for the fix! Could you please rebase to current master (which has fixed all tests)? And could you please write a test demonstrating what didn't work before and works now?

leibowitz commented 6 years ago

is there something wrong with coverage now? if the previous commit had 100% coverage, how adding an empty line can bring the coverage to 0%? doesn't make any sense to me

PetrDlouhy commented 6 years ago

@leibowitz Thanks for the great work and sorry, that I foregot about this. The coverage was probably some glitch in the infrastructure.