Commit 3649188a authored by Roman Ondráček's avatar Roman Ondráček

IQRF Net: fix RF channel inputs in TR configuration

Signed-off-by: Roman Ondráček's avatarRoman Ondráček <ondracek.roman@centrum.cz>
parent eeae4c67
Pipeline #2102 passed with stages
in 14 minutes and 36 seconds
......@@ -75,6 +75,7 @@ class TrConfigFormFactory {
*/
public function create(TrConfigPresenter $presenter): Form {
$this->presenter = $presenter;
$this->configuration = $presenter->template->configuration ?? [];
$form = $this->factory->create('iqrfnet.trConfig');
$this->addRfConfiguration($form);
$this->addRfpgwConfiguration($form);
......@@ -83,7 +84,7 @@ class TrConfigFormFactory {
$form->addSubmit('save', 'save')
->setHtmlAttribute('class', 'ajax btn btn-primary');
$form->addProtection('core.errors.form-timeout');
$form->setDefaults($presenter->template->configuration ?? []);
$form->setDefaults($this->configuration);
$form->onSuccess[] = [$this, 'save'];
return $form;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment