From 8682fc886bc971d90f56bb1b2817165d0488e064 Mon Sep 17 00:00:00 2001 From: alextselegidis Date: Thu, 18 Nov 2021 05:35:56 +0100 Subject: [PATCH] Removed the services part from the service categories page --- .../service_categories_page.php | 296 ++++-------------- assets/js/backend_categories.js | 62 ++++ assets/js/backend_categories_helper.js | 2 - 3 files changed, 129 insertions(+), 231 deletions(-) create mode 100644 assets/js/backend_categories.js diff --git a/application/views/pages/service_categories/service_categories_page.php b/application/views/pages/service_categories/service_categories_page.php index 87026ff0..dbc98fb1 100755 --- a/application/views/pages/service_categories/service_categories_page.php +++ b/application/views/pages/service_categories/service_categories_page.php @@ -9,9 +9,8 @@ - - + -
- +
-
+
+
+
+
+ - - -
-
-
- -
- - -
-
- - -
-
-
- - -

-
-
- -
-
-
- - -
- - -
- -

- - - - - -
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- - -
- -
- -
-
+ + +

+
- - -
-
-
-
-
- - -
-
- - -
-
-
-
- -

-
+
+
+
+ + +
-
-
-
- - - -
- - -
- -

- - - - - -
- - -
- -
- - -
+
+ +

+ + + + + +
+ + +
+ +
+ + +
+
diff --git a/assets/js/backend_categories.js b/assets/js/backend_categories.js new file mode 100644 index 00000000..d286652e --- /dev/null +++ b/assets/js/backend_categories.js @@ -0,0 +1,62 @@ +/* ---------------------------------------------------------------------------- + * Easy!Appointments - Open Source Web Scheduler + * + * @package EasyAppointments + * @author A.Tselegidis + * @copyright Copyright (c) 2013 - 2020, Alex Tselegidis + * @license http://opensource.org/licenses/GPL-3.0 - GPLv3 + * @link http://easyappointments.org + * @since v1.0.0 + * ---------------------------------------------------------------------------- */ + +window.BackendCategories = window.BackendCategories || {}; + +/** + * Backend Categories + * + * This namespace handles the js functionality of the backend categories page. + * + * @module BackendCategories + */ +(function (exports) { + 'use strict'; + + /** + * Contains the basic record methods for the page. + * + * @type {CategoriesHelper} + */ + var helper; + + var categoriesHelper = new CategoriesHelper(); + + /** + * Default initialize method of the page. + * + * @param {Boolean} [defaultEventHandlers] Optional (true), determines whether to bind the default event handlers. + */ + exports.initialize = function (defaultEventHandlers) { + defaultEventHandlers = defaultEventHandlers || true; + + // Instantiate helper object (category helper by default). + helper = categoriesHelper; + helper.resetForm(); + helper.filter(''); + helper.bindEventHandlers(); + + if (defaultEventHandlers) { + bindEventHandlers(); + } + + Backend.placeFooterToBottom(); + }; + + /** + * Binds the default event handlers of the backend categories page. + * + * Do not use this method if you include the "BackendCategories" namespace on another page. + */ + function bindEventHandlers() { + // + } +})(window.BackendCategories); diff --git a/assets/js/backend_categories_helper.js b/assets/js/backend_categories_helper.js index 6976ee06..e5083fe3 100644 --- a/assets/js/backend_categories_helper.js +++ b/assets/js/backend_categories_helper.js @@ -244,7 +244,6 @@ this.resetForm(); $('#filter-categories .key').val(''); this.filter('', response.id, true); - BackendServices.updateAvailableCategories(); }.bind(this) ); }; @@ -268,7 +267,6 @@ this.resetForm(); this.filter($('#filter-categories .key').val()); - BackendServices.updateAvailableCategories(); }.bind(this) ); };