Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
cmrf_form_processor
Manage
Activity
Members
Labels
Plan
Wiki
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
project
cmrf_form_processor
Merge requests
!18
Don't set a default value if the field already has a value
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Don't set a default value if the field already has a value
issue/cmrf_form_processor-3432131:3432131-submitted-values-are
into
2.0.x
Overview
1
Commits
1
Pipelines
2
Changes
1
All threads resolved!
Show all comments
Merged
Dieter Holvoet
requested to merge
issue/cmrf_form_processor-3432131:3432131-submitted-values-are
into
2.0.x
1 year ago
Overview
1
Commits
1
Pipelines
2
Changes
1
All threads resolved!
Show all comments
Expand
Closes
#3432131
0
0
Merge request reports
Compare
2.0.x
version 1
eb34767f
1 year ago
2.0.x (base)
and
latest version
latest version
40a1e17e
1 commit,
1 year ago
version 1
eb34767f
1 commit,
1 year ago
1 file
+
4
−
0
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
src/WebformSubmissionHandler.php
+
4
−
0
Options
@@ -120,6 +120,10 @@ class WebformSubmissionHandler {
if
(
!
empty
(
$values
)
&&
empty
(
$values
[
'is_error'
]))
{
unset
(
$values
[
'is_error'
]);
foreach
(
$values
as
$field
=>
$value
)
{
$existingValue
=
$webform_submission
->
getElementData
(
$field
);
if
(
$existingValue
!==
NULL
&&
$existingValue
!==
''
)
{
continue
;
}
$this
->
setDefaultValue
(
$form
,
$form_state
,
$webform_submission
,
$field
,
$value
);
}
}
Loading