But the input is valid in the legacy system from which it comes; it is just Not Applicable for the database record into which it would be inserted, based on other parameters in the db. These are two totally separate systems, and we want to use the legacy data in some cases to keep reports in sync.
-----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Dennis Kaarsemaker Sent: Saturday, July 03, 2010 11:04 AM To: [email protected] Subject: Re: Field Subclassing, or setter help needed. On za, 2010-07-03 at 10:07 -0400, Sells, Fred wrote: > I need to override the setter behavior of all the fields in all my > models. They all subclass from the same abstract model. > > Specifically if the fields already contains a special character (used > to indicate "Not Applicable") I don' want to allow it to be changed. You're doing it wrong(tm) Input validation should be done at the point where you handle input, that is in the forms you use for updating instances. -- Dennis K. They've gone to plaid! -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/django-users?hl=en. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

