| @@ -1,9 +1,8 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | 3 | namespace Templately\Builder; |
| 4 | 4 | |
| 5 | -use Templately\Core\Importer\FullSiteImport; | |
| 6 | 5 | use Templately\Utils\Helper; |
| 7 | 6 | use WP_Post; |
| 8 | 7 | use WP_Query; |
| 9 | 8 | |
| @@ -36,9 +35,9 @@ | ||
| 36 | 35 | add_filter( 'post_row_actions', [ $this, 'post_row_actions' ], 10, 2 ); |
| 37 | 36 | add_action( 'admin_footer', [ $this, 'app' ] ); |
| 38 | 37 | } |
| 39 | 38 | |
| 40 | - // add_action( 'save_post', [ $this, 'save_post' ], 11, 3 ); | |
| 39 | + add_action( 'save_post', [ $this, 'save_post' ], 11, 3 ); | |
| 41 | 40 | } |
| 42 | 41 | |
| 43 | 42 | /** |
| 44 | 43 | * If needed to add a filter for platform |
| @@ -216,9 +215,8 @@ | ||
| 216 | 215 | $types = templately()->theme_builder::$templates_manager->get_template_types(); |
| 217 | 216 | |
| 218 | 217 | $template_types = []; |
| 219 | 218 | $status_args = [ 'post_type' => 'templately_library' ]; |
| 220 | - $has_revert = FullSiteImport::has_revert(); | |
| 221 | 219 | |
| 222 | 220 | $template_types['all'] = [ |
| 223 | 221 | 'url' => add_query_arg( $status_args, 'edit.php' ), |
| 224 | 222 | 'label' => __( 'All', 'templately' ) |
| @@ -235,15 +233,9 @@ | ||
| 235 | 233 | 'label' => call_user_func( [ $type, 'get_title' ] ) |
| 236 | 234 | ]; |
| 237 | 235 | } |
| 238 | 236 | |
| 239 | - $status_args['type'] = 'settings'; | |
| 240 | - $template_types['settings'] = [ | |
| 241 | - 'url' => add_query_arg( $status_args, 'edit.php' ), | |
| 242 | - 'label' => __( 'Miscellaneous', 'templately' ) | |
| 243 | - ]; | |
| 244 | - | |
| 245 | - $this->builder::$views->get( 'builder/tabs', [ 'tabs' => $tabs, 'template_types' => $template_types, 'has_revert' => $has_revert ] ); | |
| 237 | + $this->builder::$views->get( 'builder/tabs', [ 'tabs' => $tabs, 'template_types' => $template_types ] ); | |
| 246 | 238 | return []; |
| 247 | 239 | } |
| 248 | 240 | |
| 249 | 241 | /** |