Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
WCM8 Site Information
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
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
OCIO_ODEE_Web
WCM8 Site Information
Commits
42ed451a
Commit
42ed451a
authored
6 years ago
by
Melissa Miller
Browse files
Options
Downloads
Patches
Plain Diff
set site name value back to system.site on form submit
parent
19182e61
Loading
Loading
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/Form/ModuleConfigurationForm.php
+9
-3
9 additions, 3 deletions
src/Form/ModuleConfigurationForm.php
with
9 additions
and
3 deletions
src/Form/ModuleConfigurationForm.php
+
9
−
3
View file @
42ed451a
...
...
@@ -220,6 +220,8 @@ class ModuleConfigurationForm extends ConfigFormBase {
*/
public
function
submitForm
(
array
&
$form
,
FormStateInterface
$form_state
)
{
$values
=
$form_state
->
getValues
();
//set config values unique to this module
$this
->
config
(
'wcm8_siteinfo.settings'
)
->
set
(
'prefix'
,
$values
[
'prefix'
])
->
set
(
'admin_link'
,
$values
[
'admin_link'
])
...
...
@@ -240,8 +242,12 @@ class ModuleConfigurationForm extends ConfigFormBase {
->
set
(
'instagram'
,
$values
[
'instagram'
])
->
set
(
'photos'
,
$values
[
'photos'
])
->
save
();
//set site name value back to system.site
$this
->
configFactory
->
getEditable
(
'system.site'
)
->
set
(
'name'
,
$values
[
'site_name'
])
->
save
();
parent
::
submitForm
(
$form
,
$form_state
);
}
}
\ No newline at end of file
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment