Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
typo3
qfq
Commits
83ca108f
Commit
83ca108f
authored
Sep 25, 2019
by
Carsten Rose
Browse files
Manual.rst: first notes to Multiform.
parent
bffc45b1
Pipeline
#2414
passed with stages
in 2 minutes and 50 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Documentation/Manual.rst
View file @
83ca108f
...
...
@@ -4348,10 +4348,27 @@ Action
in one of the specified required FEs.
.. _multi-
language-
form:
.. _multi-form:
Multi Language Form
-------------------
Multi Form
----------
`Multi Forms` are like regular forms, but work on 'n' records at the same time.
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.
* multiFormSql: A uniq column 'id' or '_id' is required. Columns
Simple mode
.. _multiple-languages:
Multiple languages
------------------
QFQ Forms might be configured for up to 5 different languages. Per language there is one extra field in the *Form editor*.
Which field represents which language is configured in configuration_.
...
...
extension/Classes/Core/AbstractBuildForm.php
View file @
83ca108f
...
...
@@ -237,7 +237,9 @@ abstract class AbstractBuildForm {
// Per row, iterate over all form elements
foreach
(
$parentRecords
as
$row
)
{
$this
->
store
->
setStore
(
$row
,
STORE_PARENT_RECORD
,
true
);
$jsonTmp
=
array
();
$feTmp
=
$this
->
feSpecNative
;
...
...
@@ -246,15 +248,16 @@ abstract class AbstractBuildForm {
false
,
STORE_USE_DEFAULT
,
FORM_LOAD
,
true
);
$htmlElements
.
=
Support
::
wrapTag
(
'<tr>'
,
$leftColumns
.
$rightInputs
);
// Clean for the next round
$this
->
feSpecNative
=
$feTmp
;
$this
->
store
::
unsetStore
(
STORE_RECORD
);
$rcJson
[]
=
$jsonTmp
;
}
//TODO <th>: 'class' konfigurierbar machen. Spalten ausblendbar machen. 'link' Klasse unterstuetzen.
$tableHead
=
Support
::
wrapTag
(
'<tr>'
,
$this
->
buildMultiFormTableHead
(
$parentRecords
[
0
]));
//TODO <table>: 'class' konfigurierbar machen (tablesorter)
//TODO <thead>: 'class' konfigurierbar machen (sticky)
return
'<table class="table"><thead>'
.
$tableHead
.
'</thead><tbody>'
.
$htmlElements
.
'</tbody></table>'
;
}
...
...
extension/Classes/Core/Store/Store.php
View file @
83ca108f
...
...
@@ -606,7 +606,7 @@ class Store {
* @throws \CodeException
*/
public
static
function
setVar
(
$key
,
$value
,
$storeName
,
$overWrite
=
true
)
{
// Check valid Storename
// Check valid Store
name
if
(
!
isset
(
self
::
$sanitizeStore
))
{
throw
new
\
UserFormException
(
"Unknown Store:
$storeName
"
,
ERROR_UNNOWN_STORE
);
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment