-
-
Notifications
You must be signed in to change notification settings - Fork 824
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
AdminUi - add Settings Inspector listing
- Loading branch information
Showing
3 changed files
with
153 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<div af-fieldset=""> | ||
<af-field name="title" /> | ||
<af-field name="group_name" /> | ||
<af-field name="is_env_loadable" /> | ||
<af-field name="current_layer" defn="{input_attrs: {multiple: true}}" /> | ||
<crm-search-display-table search-name="Settings_Inspector" display-name="Settings_Inspector"></crm-search-display-table> | ||
</div> |
16 changes: 16 additions & 0 deletions
16
ext/civicrm_admin_ui/ang/afsearchSettingsInspector.aff.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<?php | ||
use CRM_CivicrmAdminUi_ExtensionUtil as E; | ||
|
||
return [ | ||
'type' => 'search', | ||
'title' => E::ts('Settings Inspector'), | ||
'description' => E::ts('Allows inspecting settings on the CiviCRM site'), | ||
'icon' => 'fa-list-alt', | ||
'server_route' => 'civicrm/admin/settings-inspector', | ||
'permission' => [ | ||
'administer CiviCRM system', | ||
], | ||
'search_displays' => [ | ||
'Settings_Inspector.Settings_Inspector', | ||
], | ||
]; |
130 changes: 130 additions & 0 deletions
130
ext/civicrm_admin_ui/managed/SavedSearch_Settings_Inspector.mgd.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,130 @@ | ||
<?php | ||
use CRM_CivicrmAdminUi_ExtensionUtil as E; | ||
|
||
return [ | ||
[ | ||
'name' => 'SavedSearch_Settings_Inspector', | ||
'entity' => 'SavedSearch', | ||
'cleanup' => 'unused', | ||
'update' => 'unmodified', | ||
'params' => [ | ||
'version' => 4, | ||
'values' => [ | ||
'name' => 'Settings_Inspector', | ||
'label' => E::ts('Settings Inspector'), | ||
'api_entity' => 'SettingsMeta', | ||
'api_params' => [ | ||
'version' => 4, | ||
'select' => [ | ||
'title', | ||
'name', | ||
'description', | ||
'group_name', | ||
'is_constant', | ||
'is_env_loadable', | ||
'global_name', | ||
'current_value', | ||
'current_layer:label', | ||
], | ||
'orderBy' => [], | ||
'where' => [], | ||
], | ||
], | ||
'match' => ['name'], | ||
], | ||
], | ||
[ | ||
'name' => 'SavedSearch_Settings_Inspector_SearchDisplay_Settings_Inspector', | ||
'entity' => 'SearchDisplay', | ||
'cleanup' => 'unused', | ||
'update' => 'unmodified', | ||
'params' => [ | ||
'version' => 4, | ||
'values' => [ | ||
'name' => 'Settings_Inspector', | ||
'label' => E::ts('Settings Inspector'), | ||
'saved_search_id.name' => 'Settings_Inspector', | ||
'type' => 'table', | ||
'settings' => [ | ||
'description' => E::ts(NULL), | ||
'sort' => [], | ||
'limit' => 50, | ||
'pager' => [], | ||
'placeholder' => 5, | ||
'columns' => [ | ||
[ | ||
'type' => 'field', | ||
'key' => 'group_name', | ||
'dataType' => 'String', | ||
'label' => E::ts('Group'), | ||
'sortable' => TRUE, | ||
], | ||
[ | ||
'type' => 'field', | ||
'key' => 'title', | ||
'dataType' => 'String', | ||
'label' => E::ts('Setting'), | ||
'sortable' => TRUE, | ||
], | ||
[ | ||
'type' => 'field', | ||
'key' => 'name', | ||
'dataType' => 'String', | ||
'label' => E::ts('Machine-name'), | ||
'sortable' => TRUE, | ||
], | ||
[ | ||
'type' => 'field', | ||
'key' => 'description', | ||
'dataType' => 'String', | ||
'label' => E::ts('Description'), | ||
'sortable' => TRUE, | ||
], | ||
[ | ||
'type' => 'field', | ||
'key' => 'is_constant', | ||
'dataType' => 'Boolean', | ||
'label' => E::ts('PHP Constant?'), | ||
'sortable' => TRUE, | ||
], | ||
[ | ||
'type' => 'field', | ||
'key' => 'is_env_loadable', | ||
'dataType' => 'Boolean', | ||
'label' => E::ts('Environment Variable?'), | ||
'sortable' => TRUE, | ||
], | ||
[ | ||
'type' => 'field', | ||
'key' => 'global_name', | ||
'dataType' => 'String', | ||
'label' => E::ts('Global Name'), | ||
'sortable' => TRUE, | ||
], | ||
[ | ||
'type' => 'field', | ||
'key' => 'current_layer:label', | ||
'dataType' => 'String', | ||
'label' => E::ts('Current layer'), | ||
'sortable' => TRUE, | ||
], | ||
[ | ||
'type' => 'field', | ||
'key' => 'current_value', | ||
'dataType' => 'String', | ||
'label' => E::ts('Current value'), | ||
'sortable' => TRUE, | ||
], | ||
], | ||
'actions' => TRUE, | ||
'classes' => ['table', 'table-striped'], | ||
'actions_display_mode' => 'menu', | ||
], | ||
], | ||
'match' => [ | ||
'saved_search_id', | ||
'name', | ||
], | ||
], | ||
], | ||
]; |