Closed (fixed)
Project:
Webform
Version:
8.x-5.x-dev
Component:
Code
Priority:
Normal
Category:
Task
Assigned:
Reporter:
Created:
2 May 2021 at 07:16 UTC
Updated:
31 May 2021 at 16:24 UTC
Jump to comment: Most recent, Most recent file
WebformHandler and WebformVariant plugins use configuration settings. Settings stored in a plugin's configuration require developers to call ::getConfiguration() and then get/set the plugins configuration settings.
The current approach to setting a plugins configuration settings.
$handler = $webform->getHandler('options_limit_default');
$configuration = $handler->getConfiguration();
$configuration['settings']['limit_source_entity'] = FALSE;
$handler->setConfiguration($configuration);
$webform->save();Add WebformPlugingSettingsTrait w/ Interface
The new approach to setting a plugins configuration settings.
$webform->getHandler('options_limit_default')
->setSetting('limit_source_entity', FALSE);
$webform->save();N/A
New trait and plugin methods.
N/A
| Comment | File | Size | Author |
|---|---|---|---|
| #8 | interdiff-7-8.txt | 3.35 KB | paulocs |
| #8 | 3211832-8.patch | 22.17 KB | paulocs |
| #7 | 3211832-7.patch | 18.86 KB | jrockowitz |
| #5 | 3211832-2.patch | 16.31 KB | jrockowitz |
| #3 | 3211832-2.patch | 16.31 KB | jrockowitz |
Comments
Comment #3
jrockowitz commentedComment #4
jrockowitz commentedComment #5
jrockowitz commentedComment #7
jrockowitz commentedComment #8
paulocsI replaced some other places.
Attaching patch and interdiff. Patch must be applied in 8.x-5.x.
Comment #9
jrockowitz commentedComment #12
jrockowitz commented