From 34be39d711ed0fb17983fe60604142e4d32636f5 Mon Sep 17 00:00:00 2001 From: Carsten Rose Date: Mon, 30 Sep 2019 22:02:57 +0200 Subject: [PATCH] Update description MultiForm --- Documentation/Manual.rst | 26 +++++++++++++++++++++----- 1 file changed, 21 insertions(+), 5 deletions(-) diff --git a/Documentation/Manual.rst b/Documentation/Manual.rst index 32221a76..4f4a1640 100644 --- a/Documentation/Manual.rst +++ b/Documentation/Manual.rst @@ -4353,16 +4353,32 @@ Action Multi Form ---------- -`Multi Forms` are like regular forms, but work on 'n' records at the same time. +`Multi Forms` are like a regular with the difference that the shown FormElements are repeated for each selected record +(defined by 'multiformSql'). -Image a form with 3 native FormElements, a statement `multiFormSql={{!SELECT p.id AS _id FROM Person AS p}}` and 20 records -in table `Person`: QFQ will show a form with a table of 3 columns and 20 rows with FormElements, arranged in a table. +The Form is shown as a table. -* multiFormSql: A uniq column 'id' or '_id' is required. Columns +* multiFormSql: Selects the primary record where the defined FormElements will work on. + * A uniq column 'id' or '_id' (not shown) is mandatory and has to reflect an existing record id in table `primary table`. + * Additional columns, defined in multiFormSql, will be shown in the same line, before the FormElements. -Simple mode +Simple +====== + +* The FormElement.name represents a column of the given primary table. +* It's not possible to create new records. +* Only existing records can be selected and edited in this mode. +* Per multiFormSql row, the STORE_RECORD is filled with the whole record of the primary table, defined by `multiFormSql.id`. +* The existing values of such FormElements are automatically loaded. +* No further definition is required. + +Advanced +======== + +* The FormElement.name is not a column of the primary table. +* The insert/update/delete of each non-primary table record has to be manually defined. .. _multiple-languages: -- GitLab