Skip to content

Commit

Permalink
more
Browse files Browse the repository at this point in the history
  • Loading branch information
demeritcowboy committed Nov 17, 2024
1 parent 17d53e5 commit a4b23b7
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions tests/src/FunctionalJavascript/ExistingContactElementTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -611,16 +611,16 @@ public function testNextPrevSaveLoad() {
// Place fields for each contact on their own page and enable saving drafts
$webform = Webform::load($this->webform->getOriginalId());
// $elements = Yaml::decode($webform->get('elements'));
$elements = $webform->getElementsDecodedAndFlattened();
$this->htmlOutput('id is ' . $this->webform->getOriginalId() . ' raw elements is ' . var_export($webform->get('elements'), true) . ' elements is ' . var_export($elements, true));
$elements = $this->webform->getElementsDecodedAndFlattened();
$this->htmlOutput('id is ' . $this->webform->getOriginalId() . ' raw elements is ' . var_export($this->webform->get('elements'), true) . ' elements is ' . var_export($elements, true));
$elements_new = [
'page1' => ['#type' => 'webform_wizard_page', '#title' => 'Page 1', 'civicrm_1_contact_1_fieldset_fieldset' => $elements["civicrm_1_contact_1_fieldset_fieldset"]],
'page2' => ['#type' => 'webform_wizard_page', '#title' => 'Page 2', 'civicrm_2_contact_1_fieldset_fieldset' => $elements["civicrm_2_contact_1_fieldset_fieldset"]],
'page3' => ['#type' => 'webform_wizard_page', '#title' => 'Page 3', 'civicrm_3_contact_1_fieldset_fieldset' => $elements["civicrm_3_contact_1_fieldset_fieldset"]],
];
$webform->set('elements', Yaml::encode($elements_new));
$webform->setSetting('draft', 'all');
$webform->save();
$this->webform->set('elements', Yaml::encode($elements_new));
$this->webform->setSetting('draft', 'all');
$this->webform->save();

$this->drupalGet($this->webform->toUrl('edit-form'));
$this->htmlOutput();
Expand Down

0 comments on commit a4b23b7

Please sign in to comment.