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
b1a46b51
Commit
b1a46b51
authored
May 01, 2021
by
Carsten Rose
Browse files
Fixes #12475 During QFQ update take care that all system tables exist.
parent
b29da985
Pipeline
#5185
passed with stages
in 3 minutes and 53 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Documentation/CodingGuideline.rst
View file @
b1a46b51
...
...
@@ -81,7 +81,7 @@ QFQ content record
QFQ Form
--------
* Mandatory SIP parameter
have
to be mentioned in Form.requiredNew and/or Form.requiredEdit.
* Mandatory SIP parameter
should
to be mentioned in Form.requiredNew and/or Form.requiredEdit.
* If the title of a FormElement isn't descriptive enough, use tooltip, note or extraButtonInfo to explain to a user.
* Every Form should show a descriptive title to identify the task and current record. E.g. Not 'Person' but 'Person: John Doe'.
* Often the length of a pill title if not sufficient, use a tooltip to give a more descriptive hint.
extension/Classes/Core/Database/DatabaseUpdate.php
View file @
b1a46b51
...
...
@@ -156,8 +156,6 @@ class DatabaseUpdate {
$versionInfo
[
QFQ_VERSION_KEY_FUNCTION_VERSION
]
=
$new
;
}
$this
->
dbUpdateStatements
(
$old
,
$new
);
if
(
FEATURE_FORM_FILE_SYNC
)
{
if
(
$this
->
db
->
existTable
(
'Form'
))
{
// If Form table exists, import all form files so everything is up to date.
...
...
@@ -165,11 +163,11 @@ class DatabaseUpdate {
// create Form table and export all system forms
$this
->
db
->
playSqlFile
(
__DIR__
.
'/../../Sql/formEditor.sql'
);
FormAsF
I
le
::
exportAllForms
(
$this
->
db
);
FormAsF
i
le
::
exportAllForms
(
$this
->
db
);
}
else
{
// If not, then create Form table and export all system forms
$this
->
db
->
playSqlFile
(
__DIR__
.
'/../../Sql/formEditor.sql'
);
FormAsF
I
le
::
exportAllForms
(
$this
->
db
);
FormAsF
i
le
::
exportAllForms
(
$this
->
db
);
// import form files which existed before the new installation
FormAsFile
::
importAllForms
(
$this
->
db
,
true
);
...
...
@@ -178,6 +176,10 @@ class DatabaseUpdate {
$this
->
db
->
playSqlFile
(
__DIR__
.
'/../../Sql/formEditor.sql'
);
}
// Perform dbUpdate only after formEditor.sql has been played:
// in case a new system table has been added between old and new and there is an dbUpdate on the new system table now.
$this
->
dbUpdateStatements
(
$old
,
$new
);
FormAsFile
::
importSystemForms
(
$this
->
db
);
Logger
::
logMessage
(
date
(
'Y.m.d H:i:s '
)
.
": Updated from QFQ version '
$old
' to '
$new
'"
,
Path
::
absoluteQfqLogFile
());
...
...
@@ -195,7 +197,7 @@ class DatabaseUpdate {
if
(
version_compare
(
$old
,
'19.9.0'
)
===
-
1
)
{
$this
->
updateSpecialColumns
();
if
(
FEATURE_FORM_FILE_SYNC
)
{
FormAsF
I
le
::
exportAllForms
(
$this
->
db
);
FormAsF
i
le
::
exportAllForms
(
$this
->
db
);
}
}
...
...
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