@@ 1237-1259 (lines=23) @@ | ||
1234 | } |
|
1235 | ||
1236 | ||
1237 | protected function _category_details($view) { |
|
1238 | ||
1239 | //load formatter helper |
|
1240 | EE_Registry::instance()->load_helper( 'Formatter' ); |
|
1241 | //load field generator helper |
|
1242 | EE_Registry::instance()->load_helper( 'Form_Fields' ); |
|
1243 | ||
1244 | $route = $view == 'edit' ? 'update_category' : 'insert_category'; |
|
1245 | $this->_set_add_edit_form_tags($route); |
|
1246 | ||
1247 | $this->_set_category_object(); |
|
1248 | $id = !empty($this->_category->id) ? $this->_category->id : ''; |
|
1249 | ||
1250 | $delete_action = 'delete_category'; |
|
1251 | ||
1252 | $redirect = EE_Admin_Page::add_query_args_and_nonce( array( 'action' => 'category_list' ), $this->_admin_base_url ); |
|
1253 | ||
1254 | $this->_set_publish_post_box_vars( 'VEN_CAT_ID', $id, $delete_action, $redirect ); |
|
1255 | ||
1256 | //take care of contents |
|
1257 | $this->_template_args['admin_page_content'] = $this->_category_details_content(); |
|
1258 | $this->display_admin_page_with_sidebar(); |
|
1259 | } |
|
1260 | ||
1261 | ||
1262 |
@@ 2175-2198 (lines=24) @@ | ||
2172 | } |
|
2173 | ||
2174 | ||
2175 | protected function _category_details($view) { |
|
2176 | ||
2177 | //load formatter helper |
|
2178 | EE_Registry::instance()->load_helper( 'Formatter' ); |
|
2179 | //load field generator helper |
|
2180 | EE_Registry::instance()->load_helper( 'Form_Fields' ); |
|
2181 | ||
2182 | $route = $view == 'edit' ? 'update_category' : 'insert_category'; |
|
2183 | $this->_set_add_edit_form_tags($route); |
|
2184 | ||
2185 | $this->_set_category_object(); |
|
2186 | $id = !empty($this->_category->id) ? $this->_category->id : ''; |
|
2187 | ||
2188 | $delete_action = 'delete_category'; |
|
2189 | ||
2190 | //custom redirect |
|
2191 | $redirect = EE_Admin_Page::add_query_args_and_nonce( array('action' => 'category_list'), $this->_admin_base_url ); |
|
2192 | ||
2193 | $this->_set_publish_post_box_vars( 'EVT_CAT_ID', $id, $delete_action, $redirect ); |
|
2194 | ||
2195 | //take care of contents |
|
2196 | $this->_template_args['admin_page_content'] = $this->_category_details_content(); |
|
2197 | $this->display_admin_page_with_sidebar(); |
|
2198 | } |
|
2199 | ||
2200 | ||
2201 |