Saturday, October 23, 2010

Re: Forms: set required value at runtime

Bence,

I think your problem is related to the second case described in documentation about validation fields that depend on each other [1].

Just an observation about your design, if I may: I believe you should explicitly set and store both addresses. You will ease user task by providing a widget that will set the second address according the first, activated or not by default (I prefer not as your helper offer a direct one click "auto-fill" as you can encounter in many date fields with "today" button).

Regards

[1] http://docs.djangoproject.com/en/dev/ref/forms/validation/#cleaning-and-validating-fields-that-depend-on-each-other

No comments:

Post a Comment