Review Board

beta

Clean up several aspects of the models

Submitted
Updated 4 months, 1 week ago

Christian Hammond Reviewers
trunk reviewboard
None Review Board SVN
Cleaned up some of the models by giving all relationship fields explicit related_name fields, rather than using Django's pre-generated defaults. This makes for more natural names and is something we'd want to do before extensions land later on.

This also moves error types and the custom Manager in reviews to their own files.
All unit tests pass.
Ship it!
Posted 4 months, 1 week ago (July 10th, 2008, 11:54 p.m.)
What implications does this have for migrations?
  1. Christian Hammond 4 months, 1 week ago (July 11th, 2008, 12:10 a.m.)
    None of these changes cause database changes. I checked. They're all internal to Django.
/trunk/reviewboard/reviews/datagrids.py (Diff revision 1)
165
        return str(obj.reviewrequest_set.filter(public=True,
166
        return str(getattr(obj, self.field_name).filter(public=True,
166
                                                status='P').count())
167
                                                        status='P').count())
I can't tell if it's just my browser or not, but indentation here looks weird.
  1. Christian Hammond 4 months, 1 week ago (July 11th, 2008, 12:09 a.m.)
    It's just you :)