APIv4 explorer - move metadata into .ang.php file
authorColeman Watts <coleman@civicrm.org>
Wed, 30 Jun 2021 20:48:40 +0000 (16:48 -0400)
committerColeman Watts <coleman@civicrm.org>
Wed, 30 Jun 2021 20:48:40 +0000 (16:48 -0400)
CRM/Api4/Page/Api4Explorer.php
ang/api4Explorer.ang.php

index 655800bfe596c0d48adb409bc2590e2d1c6eb57c..af188f31360963e7349b9bc4d3db62f4771d4e93 100644 (file)
@@ -40,9 +40,7 @@ class CRM_Api4_Page_Api4Explorer extends CRM_Core_Page {
       'groupOptions' => array_column((array) $groupOptions, 'options', 'name'),
     ];
     Civi::resources()
-      ->addBundle('bootstrap3')
       ->addVars('api4', $vars)
-      ->addPermissions(['access debug output', 'edit groups', 'administer reserved groups'])
       ->addScriptFile('civicrm', 'bower_components/js-yaml/dist/js-yaml.min.js')
       ->addScriptFile('civicrm', 'bower_components/marked/marked.min.js')
       ->addScriptFile('civicrm', 'bower_components/google-code-prettify/bin/prettify.min.js')
index 2eec108aaf14abe9d0c390e7640a8c7c12c596ef..d0ac2be6ecfea710ecc7c38c1641e5ede84a8b76 100644 (file)
@@ -1,5 +1,5 @@
 <?php
-// Autoloader data for Api4 explorer.
+// Autoloader data for Api4 Explorer Angular module.
 return [
   'ext' => 'civicrm',
   'js' => [
@@ -13,5 +13,7 @@ return [
     'ang/api4Explorer',
   ],
   'basePages' => [],
+  'bundles' => ['bootstrap3'],
+  'permissions' => ['access debug output', 'edit groups', 'administer reserved groups'],
   'requires' => ['crmUi', 'crmUtil', 'ngRoute', 'crmRouteBinder', 'ui.sortable', 'api4', 'ngSanitize', 'dialogService', 'checklist-model'],
 ];