Am 27.09.2007 um 05:35 schrieb Stephan Richter:

On Wednesday 26 September 2007 09:06, Michael Howitz wrote:
   This solution requests that the back-end supports non-optimistic
save-points. But we can get rid of the Data class.

We'll start an implementation of the second approach on a branch of
z3c.form now to show if it works.

I really like the second approach, if you can get it working.

After thinking it over we decided to implement the first approach (change z3c.form.validator.Data to read the value of a field missing in he form on the object).

We put our changes into the branch gocept-invariants.

The reasons to change our decision where the following:

- the second approach (using save-points) requires save-point support on the back-end and breaks without this support

- using save-points would require to change the structure of z3c.form: till now the complete validation is done by z3c.form.field.FieldWidgets, using save-points validation gets split up into validation of field contents in FieldWidgets and validation of the invariants. The validation of the invariants has to be implemented at least twice: in AddForm and EditForm because saving form values is done completely different in these classes. So someone creating a direct subclass of z3c.form.form.Form has to do things again or we need additional changes in the structure.

Any thoughts?

Yours sincerely,
Michael Howitz

gocept gmbh & co. kg · forsterstrasse 29 · 06112 halle/saale · fon: +49 345 12298898 · fax: +49 345 12298891

Zope3-dev mailing list

Reply via email to