| @@ 1259-1293 (lines=35) @@ | ||
| 1256 | ||
| 1257 | ||
| 1258 | ||
| 1259 | protected function _category_details_content() { |
|
| 1260 | $editor_args['category_desc'] = array( |
|
| 1261 | 'type' => 'wp_editor', |
|
| 1262 | 'value' => EEH_Formatter::admin_format_content($this->_category->category_desc), |
|
| 1263 | 'class' => 'my_editor_custom', |
|
| 1264 | 'wpeditor_args' => array( 'media_buttons' => FALSE ) |
|
| 1265 | ); |
|
| 1266 | $_wp_editor = $this->_generate_admin_form_fields( $editor_args, 'array' ); |
|
| 1267 | ||
| 1268 | $all_terms = get_terms( array('espresso_venue_categories' ), array( 'hide_empty' => 0, 'exclude' => array( $this->_category->id ) ) ); |
|
| 1269 | ||
| 1270 | //setup category select for term parents. |
|
| 1271 | $category_select_values[] = array( |
|
| 1272 | 'text' => __('No Parent', 'event_espresso'), |
|
| 1273 | 'id' => 0 |
|
| 1274 | ); |
|
| 1275 | foreach ( $all_terms as $term ) { |
|
| 1276 | $category_select_values[] = array( |
|
| 1277 | 'text' => $term->name, |
|
| 1278 | 'id' => $term->term_id |
|
| 1279 | ); |
|
| 1280 | } |
|
| 1281 | ||
| 1282 | $category_select = EEH_Form_Fields::select_input( 'category_parent', $category_select_values, $this->_category->parent ); |
|
| 1283 | $template_args = array( |
|
| 1284 | 'category' => $this->_category, |
|
| 1285 | 'category_select' => $category_select, |
|
| 1286 | 'unique_id_info_help_link' => $this->_get_help_tab_link('unique_id_info'), |
|
| 1287 | 'category_desc_editor' => $_wp_editor['category_desc']['field'], |
|
| 1288 | 'disable' => '', |
|
| 1289 | 'disabled_message' =>FALSE |
|
| 1290 | ); |
|
| 1291 | $template = EVENTS_TEMPLATE_PATH . 'event_category_details.template.php'; |
|
| 1292 | return EEH_Template::display_template($template, $template_args, TRUE ); |
|
| 1293 | } |
|
| 1294 | ||
| 1295 | ||
| 1296 | protected function _delete_categories() { |
|
| @@ 2146-2181 (lines=36) @@ | ||
| 2143 | ||
| 2144 | ||
| 2145 | ||
| 2146 | protected function _category_details_content() { |
|
| 2147 | $editor_args['category_desc'] = array( |
|
| 2148 | 'type' => 'wp_editor', |
|
| 2149 | 'value' => EEH_Formatter::admin_format_content($this->_category->category_desc), |
|
| 2150 | 'class' => 'my_editor_custom', |
|
| 2151 | 'wpeditor_args' => array('media_buttons' => FALSE ) |
|
| 2152 | ); |
|
| 2153 | $_wp_editor = $this->_generate_admin_form_fields( $editor_args, 'array' ); |
|
| 2154 | ||
| 2155 | $all_terms = get_terms( array('espresso_event_categories' ), array( 'hide_empty' => 0, 'exclude' => array( $this->_category->id ) ) ); |
|
| 2156 | ||
| 2157 | //setup category select for term parents. |
|
| 2158 | $category_select_values[] = array( |
|
| 2159 | 'text' => __('No Parent', 'event_espresso'), |
|
| 2160 | 'id' => 0 |
|
| 2161 | ); |
|
| 2162 | foreach ( $all_terms as $term ) { |
|
| 2163 | $category_select_values[] = array( |
|
| 2164 | 'text' => $term->name, |
|
| 2165 | 'id' => $term->term_id |
|
| 2166 | ); |
|
| 2167 | } |
|
| 2168 | ||
| 2169 | $category_select = EEH_Form_Fields::select_input( 'category_parent', $category_select_values, $this->_category->parent ); |
|
| 2170 | ||
| 2171 | $template_args = array( |
|
| 2172 | 'category' => $this->_category, |
|
| 2173 | 'category_select' => $category_select, |
|
| 2174 | 'unique_id_info_help_link' => $this->_get_help_tab_link('unique_id_info'), |
|
| 2175 | 'category_desc_editor' => $_wp_editor['category_desc']['field'], |
|
| 2176 | 'disable' => '', |
|
| 2177 | 'disabled_message' => FALSE |
|
| 2178 | ); |
|
| 2179 | $template = EVENTS_TEMPLATE_PATH . 'event_category_details.template.php'; |
|
| 2180 | return EEH_Template::display_template($template, $template_args, TRUE ); |
|
| 2181 | } |
|
| 2182 | ||
| 2183 | ||
| 2184 | protected function _delete_categories() { |
|