[TYPO3-mvc] 1:n childs unconected but not deleted from database
christian oettinger
christian.oettinger at gmx.de
Wed Nov 24 16:46:44 CET 2010
Hi list,
we have a big object with 1:n related childs. We divide the
creation/editing of the object in multiple forms (multi-step, we thus
use partial Validation) containing fields of the parent(s) and childs.
Example of one Form:
Patient (parent) Fields: Name, Age, Sex
Medcation1 (child): Name, Dose
Medication2 (child): Name, Dose
Maedication3 (child): Name, Dose
When sending the Form we manipulate the request - if all fields of a
child are empty we delete the child form the request, so it will not be
validated nore persisted.
Everything works fine so far. Now to the question:
When deleting all fields of a child that has already been persisted
previously, the child will be removed from the object as intended - but
the now useless child data will remain in the database, unconnected.
It will not be deleted when there is no deleted-field.
If there is a deleted-field, it will not be set.
Is there a way to change this?
Or am I missing something?
We are using extbase 1.2.1
Thanks for any hint!
christian (oe)
More information about the TYPO3-project-typo3v4mvc
mailing list