mixin/ang-php - Convert live Angular modules from `hook_angularModules` to `<mixin>`
[civicrm-core.git] / ext / message_admin / message_admin.php
1 <?php
2
3 require_once 'message_admin.civix.php';
4 // phpcs:disable
5 use CRM_MessageAdmin_ExtensionUtil as E;
6 // phpcs:enable
7
8 /**
9 * Implements hook_civicrm_config().
10 *
11 * @link https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_config/
12 */
13 function message_admin_civicrm_config(&$config) {
14 _message_admin_civix_civicrm_config($config);
15 }
16
17 /**
18 * Implements hook_civicrm_xmlMenu().
19 *
20 * @link https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_xmlMenu
21 */
22 function message_admin_civicrm_xmlMenu(&$files) {
23 _message_admin_civix_civicrm_xmlMenu($files);
24 }
25
26 /**
27 * Implements hook_civicrm_install().
28 *
29 * @link https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_install
30 */
31 function message_admin_civicrm_install() {
32 _message_admin_civix_civicrm_install();
33 }
34
35 /**
36 * Implements hook_civicrm_postInstall().
37 *
38 * @link https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_postInstall
39 */
40 function message_admin_civicrm_postInstall() {
41 _message_admin_civix_civicrm_postInstall();
42 }
43
44 /**
45 * Implements hook_civicrm_uninstall().
46 *
47 * @link https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_uninstall
48 */
49 function message_admin_civicrm_uninstall() {
50 _message_admin_civix_civicrm_uninstall();
51 }
52
53 /**
54 * Implements hook_civicrm_enable().
55 *
56 * @link https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_enable
57 */
58 function message_admin_civicrm_enable() {
59 _message_admin_civix_civicrm_enable();
60 }
61
62 /**
63 * Implements hook_civicrm_disable().
64 *
65 * @link https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_disable
66 */
67 function message_admin_civicrm_disable() {
68 _message_admin_civix_civicrm_disable();
69 }
70
71 /**
72 * Implements hook_civicrm_upgrade().
73 *
74 * @link https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_upgrade
75 */
76 function message_admin_civicrm_upgrade($op, CRM_Queue_Queue $queue = NULL) {
77 return _message_admin_civix_civicrm_upgrade($op, $queue);
78 }
79
80 /**
81 * Implements hook_civicrm_managed().
82 *
83 * Generate a list of entities to create/deactivate/delete when this module
84 * is installed, disabled, uninstalled.
85 *
86 * @link https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_managed
87 */
88 function message_admin_civicrm_managed(&$entities) {
89 _message_admin_civix_civicrm_managed($entities);
90 }
91
92 /**
93 * Implements hook_civicrm_caseTypes().
94 *
95 * Generate a list of case-types.
96 *
97 * Note: This hook only runs in CiviCRM 4.4+.
98 *
99 * @link https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_caseTypes
100 */
101 function message_admin_civicrm_caseTypes(&$caseTypes) {
102 _message_admin_civix_civicrm_caseTypes($caseTypes);
103 }
104
105 /**
106 * Implements hook_civicrm_entityTypes().
107 *
108 * Declare entity types provided by this module.
109 *
110 * @link https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_entityTypes
111 */
112 function message_admin_civicrm_entityTypes(&$entityTypes) {
113 _message_admin_civix_civicrm_entityTypes($entityTypes);
114 }
115
116 /**
117 * Implements hook_civicrm_themes().
118 */
119 function message_admin_civicrm_themes(&$themes) {
120 _message_admin_civix_civicrm_themes($themes);
121 }
122
123 // --- Functions below this ship commented out. Uncomment as required. ---
124
125 /**
126 * Implements hook_civicrm_preProcess().
127 *
128 * @link https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_preProcess
129 */
130 //function message_admin_civicrm_preProcess($formName, &$form) {
131 //
132 //}
133
134 /**
135 * Implements hook_civicrm_navigationMenu().
136 *
137 * @link https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_navigationMenu
138 */
139 //function message_admin_civicrm_navigationMenu(&$menu) {
140 // _message_admin_civix_insert_navigation_menu($menu, 'Mailings', array(
141 // 'label' => E::ts('New subliminal message'),
142 // 'name' => 'mailing_subliminal_message',
143 // 'url' => 'civicrm/mailing/subliminal',
144 // 'permission' => 'access CiviMail',
145 // 'operator' => 'OR',
146 // 'separator' => 0,
147 // ));
148 // _message_admin_civix_navigationMenu($menu);
149 //}
150
151 /**
152 * Mark these fields as translateable.
153 * @see CRM_Utils_Hook::translateFields
154 */
155 function message_admin_civicrm_translateFields(&$fields) {
156 $fields['civicrm_msg_template']['msg_subject'] = TRUE;
157 $fields['civicrm_msg_template']['msg_text'] = TRUE;
158 $fields['civicrm_msg_template']['msg_html'] = TRUE;
159 }