Afform - fix loading embedded blocks
authorColeman Watts <coleman@civicrm.org>
Sat, 25 Sep 2021 00:13:54 +0000 (20:13 -0400)
committerColeman Watts <coleman@civicrm.org>
Sat, 25 Sep 2021 00:13:54 +0000 (20:13 -0400)
ext/afform/admin/Civi/Api4/Action/Afform/LoadAdminData.php

index 2724c2a3497fb218f485c3c84268b60a36c1d8f8..81ed486a81e28f4801b4ee5974f7a49104304fa6 100644 (file)
@@ -116,6 +116,7 @@ class LoadAdminData extends \Civi\Api4\Generic\AbstractAction {
         if (!isset($info['blocks'][$blockTag])) {
           // Load full contents of block used on the form, then recurse into it
           $embeddedForm = Afform::get($this->checkPermissions)
+            ->addSelect('*', 'directive_name')
             ->setFormatWhitespace(TRUE)
             ->setLayoutFormat('shallow')
             ->addWhere('directive_name', '=', $blockTag)