From 4529e958f95f3e1c8b9d0341705674e80ba8334c Mon Sep 17 00:00:00 2001 From: Shreesh Arora Date: Wed, 9 Oct 2024 16:58:28 +0530 Subject: [PATCH 1/2] Added: upgrade files --- install/upgrade/php/add_new_categores_160.php | 65 +++ .../php/add_new_order_refund_states_160.php | 152 +++++++ install/upgrade/php/add_new_tabs_160.php | 68 +++ ...ate_entry_for_payment_detail_table_160.php | 12 + .../move_hotel_address_to_address_table.php | 38 ++ .../php/move_hotel_categoryes_to_location.php | 59 +++ .../php/update_order_payment_detail_160.php | 96 +++++ install/upgrade/sql/1.5.0.sql | 4 +- install/upgrade/sql/1.6.0.0.sql | 222 ++++++++++ modules/blockcurrencies/upgrade/index.php | 29 ++ .../blockcurrencies/upgrade/upgrade-1.1.0.php | 49 +++ modules/blocklanguages/upgrade/index.php | 29 ++ .../blocklanguages/upgrade/upgrade-1.6.0.php | 49 +++ .../upgrade/upgrade-1.1.2.php | 42 ++ modules/dashguestcycle/upgrade/index.php | 29 ++ .../dashguestcycle/upgrade/upgrade-1.0.1.php | 46 ++ modules/dashoccupancy/upgrade/index.php | 29 ++ .../dashoccupancy/upgrade/upgrade-1.0.1.php | 46 ++ .../upgrade/upgrade-1.5.0.php | 401 ++++++++++++++++++ modules/statsforecast/upgrade/index.php | 29 ++ .../statsforecast/upgrade/upgrade-1.4.3.php | 44 ++ modules/wkfooteraboutblock/upgrade/index.php | 29 ++ .../upgrade/upgrade-1.0.4.php | 41 ++ .../wkfooterpaymentblock/upgrade/index.php | 29 ++ .../upgrade/upgrade-1.1.5.php | 41 ++ .../upgrade/upgrade-2.0.6.php | 41 ++ modules/wkhotelroom/upgrade/upgrade-1.1.8.php | 41 ++ .../upgrade/upgrade-1.1.6.php | 41 ++ 28 files changed, 1799 insertions(+), 2 deletions(-) create mode 100644 install/upgrade/php/add_new_categores_160.php create mode 100644 install/upgrade/php/add_new_order_refund_states_160.php create mode 100644 install/upgrade/php/add_new_tabs_160.php create mode 100644 install/upgrade/php/create_entry_for_payment_detail_table_160.php create mode 100644 install/upgrade/php/move_hotel_address_to_address_table.php create mode 100644 install/upgrade/php/move_hotel_categoryes_to_location.php create mode 100644 install/upgrade/php/update_order_payment_detail_160.php create mode 100644 install/upgrade/sql/1.6.0.0.sql create mode 100644 modules/blockcurrencies/upgrade/index.php create mode 100644 modules/blockcurrencies/upgrade/upgrade-1.1.0.php create mode 100644 modules/blocklanguages/upgrade/index.php create mode 100644 modules/blocklanguages/upgrade/upgrade-1.6.0.php create mode 100644 modules/blocknavigationmenu/upgrade/upgrade-1.1.2.php create mode 100644 modules/dashguestcycle/upgrade/index.php create mode 100644 modules/dashguestcycle/upgrade/upgrade-1.0.1.php create mode 100644 modules/dashoccupancy/upgrade/index.php create mode 100644 modules/dashoccupancy/upgrade/upgrade-1.0.1.php create mode 100644 modules/hotelreservationsystem/upgrade/upgrade-1.5.0.php create mode 100644 modules/statsforecast/upgrade/index.php create mode 100644 modules/statsforecast/upgrade/upgrade-1.4.3.php create mode 100644 modules/wkfooteraboutblock/upgrade/index.php create mode 100644 modules/wkfooteraboutblock/upgrade/upgrade-1.0.4.php create mode 100644 modules/wkfooterpaymentblock/upgrade/index.php create mode 100644 modules/wkfooterpaymentblock/upgrade/upgrade-1.1.5.php create mode 100644 modules/wkhotelfeaturesblock/upgrade/upgrade-2.0.6.php create mode 100644 modules/wkhotelroom/upgrade/upgrade-1.1.8.php create mode 100644 modules/wktestimonialblock/upgrade/upgrade-1.1.6.php diff --git a/install/upgrade/php/add_new_categores_160.php b/install/upgrade/php/add_new_categores_160.php new file mode 100644 index 000000000..f144ac0f4 --- /dev/null +++ b/install/upgrade/php/add_new_categores_160.php @@ -0,0 +1,65 @@ + 'Locations', + 'description' => '', + 'id_parent' => Configuration::get('PS_HOME_CATEGORY'), + 'config_key' => 'PS_LOCATIONS_CATEGORY' + ), + array( + 'name' => 'Services', + 'description' => '', + 'id_parent' => Configuration::get('PS_HOME_CATEGORY'), + 'config_key' => 'PS_SERVICE_CATEGORY' + ) + ); + + $groupIds = array(); + $objGroup = new Group(); + $dataGroupIds = $objGroup->getGroups(1, $id_shop = false); + + foreach ($dataGroupIds as $key => $value) { + $groupIds[] = $value['id_group']; + } + $res = true; + foreach($categories as $category) { + $objCategory = new Category(); + $objCategory->name = array(); + $objCategory->description = array(); + $objCategory->link_rewrite = array(); + + foreach (Language::getLanguages(true) as $lang) { + $objCategory->name[$lang['id_lang']] = $category['name']; + $objCategory->description[$lang['id_lang']] = $category['description']; + $objCategory->link_rewrite[$lang['id_lang']] = Tools::link_rewrite($category['name']); + } + $objCategory->id_parent = $category['id_parent']; + $objCategory->groupBox = $groupIds; + if ($objCategory->save()) { + $res &= Configuration::updateValue($category['config_key'], $objCategory->id); + } + } + + return $res; +} \ No newline at end of file diff --git a/install/upgrade/php/add_new_order_refund_states_160.php b/install/upgrade/php/add_new_order_refund_states_160.php new file mode 100644 index 000000000..82bc9c0a0 --- /dev/null +++ b/install/upgrade/php/add_new_order_refund_states_160.php @@ -0,0 +1,152 @@ + array( + 'invoice' => '0', + 'send_email' => '1', + 'color' => '#4169E1', + 'unremovable' => '1', + 'hidden' => '0', + 'logable' => '0', + 'delivery' => '0', + 'shipped' => '0', + 'paid' => '0', + 'pdf_delivery' => '0', + 'pdf_invoice' => '0', + 'lang' => array( + 'name' => 'Awaiting payment', + 'template' => 'awaiting_payment', + ), + 'key' => 'PS_OS_AWAITING_PAYMENT' + ), + 'Payment_accepted' => array( + 'id' => Configuration::get('PS_OS_PAYMENT'), + 'lang' => array( + 'template' => 'payment_accepted', + ), + 'key' => 'PS_OS_PAYMENT_ACCEPTED' + ), + 'Processing_in_progress' => array( + 'id' => Configuration::get('PS_OS_PREPARATION'), + 'lang' => array( + 'template' => 'processing', + ), + 'key' => 'PS_OS_PROCESSING' + ), + 'Payment_remotely_accepted' => array( + 'id' => Configuration::get('PS_OS_WS_PAYMENT'), + 'paid' => '0', + 'send_email' => '0', + 'lang' => array( + 'template' => 'payment_accepted', + ), + 'key' => 'PS_OS_REMOTE_PAYMENT_ACCEPTED' + ), + 'Overbooking_paid' => array( + 'id' => Configuration::get('PS_OS_OUTOFSTOCK_PAID'), + 'lang' => array( + 'name' => 'Overbooking (paid)', + 'template' => '', + ), + 'key' => 'PS_OS_OVERBOOKING_PAID' + ), + 'Overbooking_unpaid' => array( + 'id' => Configuration::get('PS_OS_OUTOFSTOCK_UNPAID'), + 'lang' => array( + 'name' => 'Overbooking (not paid)', + 'template' => '', + ), + 'key' => 'PS_OS_OVERBOOKING_UNPAID' + ), + 'Partial_payment_accepted' => array( + 'id' => Configuration::get('PS_OS_PARTIAL_PAYMENT'), + 'color' => '#F0B656', + 'logable' => 1, + 'send_email' => 1, + 'lang' => array( + 'name' => 'Partial payment accepted', + 'template' => 'payment_accepted', + ), + 'key' => 'PS_OS_PARTIAL_PAYMENT_ACCEPTED' + ), + ); + foreach ($orderStates as $stateName => $state) { + if (isset($state['id']) && $state['id']) { + $objState = new OrderState($state['id']); + } else { + $objState = new OrderState(); + } + foreach ($state as $key => $stateValue) { + if ($key == 'lang') { + foreach ($stateValue as $key => $value) { + foreach (Language::getLanguages(true) as $lang) { + $objState->{$key}[$lang['id_lang']] = $value; + } + } + } else { + $objState->{$key} = $stateValue; + } + } + if ($objState->save()) { + // update order status image + if (file_exists(dirname(__FILE__).'/../../data/img/os/'.$stateName.'.gif')) { + copy(dirname(__FILE__).'/../../data/img/os/'.$stateName.'.gif', _PS_ROOT_DIR_.'/img/os/'.$objState->id.'.gif'); + } + + // update order status id in configuration table + if (isset($state['key']) && $state['key']) { + Configuration::updateValue($state['key'], $objState->id); + } + } + } + + $refundStatesDelete = array( + 'recieved' => array( + 'id' => 2, + 'update_id' => 1 + ) + ); + + foreach ($refundStatesDelete as $state) { + Db::getInstance()->delete('order_return_state', '`id_order_return_state` = '.$state['id']); + Db::getInstance()->delete('order_return_state_lang', '`id_order_return_state` = '.$state['id']); + Db::getInstance()->update('order_return', array('state' => $state['update_id']), '`state` = '.$state['id']); + } + + $refundStatusUpdate = array( + 'waiting' => array( + 'id' => 1, + 'fields_lang' => array( + 'name' => 'Pending', + 'customer_template' => 'order_refund_pending_customer', + 'admin_template' => 'order_refund_pending_admin' + ), + ) + ); + foreach ($refundStatusUpdate as $state) { + Db::getInstance()->update('order_return_state_lang', $state['fields_lang'], '`id_order_return_state` = '.$state['id']); + } + + return true; +} \ No newline at end of file diff --git a/install/upgrade/php/add_new_tabs_160.php b/install/upgrade/php/add_new_tabs_160.php new file mode 100644 index 000000000..f4dcd1f64 --- /dev/null +++ b/install/upgrade/php/add_new_tabs_160.php @@ -0,0 +1,68 @@ + 'AdminNormalProducts', + 'name' => 'Manage Service Products', + 'id_parent' => (int) Tab::getIdFromClassName('AdminCatalog'), + 'position_after' => 'AdminProducts' + ), + array( + 'className' => 'AdminCategories', + 'name' => 'Categories', + 'id_parent' => (int) Tab::getIdFromClassName('AdminCatalog'), + 'position_after' => 'AdminNormalProducts' + ), + array( + 'className' => 'AdminModulesCatalog', + 'name' => 'Modules Catalog', + 'id_parent' => (int) Tab::getIdFromClassName('AdminParentModules'), + 'position_after' => 'AdminModules' + ) + ); + + + foreach($tabs as $tab) { + $objTab = new Tab(); + $objTab->active = 1; + $objTab->class_name = $tab['className']; + $objTab->name = array(); + + foreach (Language::getLanguages(true) as $lang) { + $objTab->name[$lang['id_lang']] = $tab['name']; + } + + $objTab->id_parent = (int)$tab['id_parent']; + + if ($objTab->add()) { + //Set position Tab + if (Validate::isLoadedObject( + $objTabForPosition = Tab::getInstanceFromClassName($tab['position_after']) + )) { + $objTab->updatePosition(0, ($objTabForPosition->position + 1)); + } + } + } + + return true; +} \ No newline at end of file diff --git a/install/upgrade/php/create_entry_for_payment_detail_table_160.php b/install/upgrade/php/create_entry_for_payment_detail_table_160.php new file mode 100644 index 000000000..c1782e65e --- /dev/null +++ b/install/upgrade/php/create_entry_for_payment_detail_table_160.php @@ -0,0 +1,12 @@ +executeS($sql))) { + + } +} \ No newline at end of file diff --git a/install/upgrade/php/move_hotel_address_to_address_table.php b/install/upgrade/php/move_hotel_address_to_address_table.php new file mode 100644 index 000000000..197dd0830 --- /dev/null +++ b/install/upgrade/php/move_hotel_address_to_address_table.php @@ -0,0 +1,38 @@ +executeS($sql)) { + foreach($addresses as &$address) { + $address['firstname'] = preg_replace('/[0-9]+/', '', $address['firstname']); + $address['lastname'] = preg_replace('/[0-9]+/', '', $address['lastname']); + } + return Db::getInstance()->insert('address', $addresses); + } +} \ No newline at end of file diff --git a/install/upgrade/php/move_hotel_categoryes_to_location.php b/install/upgrade/php/move_hotel_categoryes_to_location.php new file mode 100644 index 000000000..746705180 --- /dev/null +++ b/install/upgrade/php/move_hotel_categoryes_to_location.php @@ -0,0 +1,59 @@ +executeS($sql); + $categoriesToUpdate = array(); + foreach ($hotels as $hotel) { + $objCategory = new Category($hotel['id_category']); + $categories = $objCategory->getParentsCategories(); + foreach ($categories as $category) { + if ($category['level_depth'] == 2 + && $category['id_category'] != $idLocationCategory + && $category['id_parent'] != $idLocationCategory + ) { + if (!in_array($category['id_category'], $categoriesToUpdate)) { + $categoriesToUpdate[] = $category['id_category']; + } + } + } + } + + // update country categories id_parent + db::getInstance()->update('category', + array('id_parent' => $idLocationCategory), + 'id_category IN ('.implode(', ', $categoriesToUpdate).')' + ); + + // regenerate category tree + Category::regenerateEntireNtree(); + $objCategory = new Category(); + $objCategory->recalculateLevelDepth($idLocationCategory); + + return true; + } else { + return false; + } +} \ No newline at end of file diff --git a/install/upgrade/php/update_order_payment_detail_160.php b/install/upgrade/php/update_order_payment_detail_160.php new file mode 100644 index 000000000..783996771 --- /dev/null +++ b/install/upgrade/php/update_order_payment_detail_160.php @@ -0,0 +1,96 @@ +executeS('SELECT `order_reference`, `id_order_payment`, `amount` FROM `'._DB_PREFIX_.'order_payment`')) { + $references = array(); + foreach ($orderPayment as $payment) { + if (!isset($references[$payment['order_reference']])) { + $references[$payment['order_reference']] = array(); + } + $references[$payment['order_reference']][] = array( + 'id_order_payment' => $payment['id_order_payment'], + 'amount' => $payment['amount'] + ); + } + if (!empty($references)) { + foreach ($references as $key => $reference) { + $orders = Db::getInstance()->executeS('SELECT `id_order`, `advance_paid_amount` FROM `'._DB_PREFIX_.'orders` WHERE `reference` = "'.pSQL($key).'"'); + if (count($orders) == 1) { + $order = array_shift($orders); + foreach ($reference as $payment) { + $objOrderPaymentDetail = new OrderPaymentDetail(); + $objOrderPaymentDetail->id_order_payment = $payment['id_order_payment']; + $objOrderPaymentDetail->id_order = $order['id_order']; + $objOrderPaymentDetail->amount = $payment['amount']; + $objOrderPaymentDetail->save(); + } + } else { + foreach ($reference as $key => $payment) { + if ($key === 0) { + $totalAdvancePayment = array_sum(array_column($orders, 'advance_paid_amount')); + if ($payment['amount'] == $totalAdvancePayment) { + $lastOrder = end($orders); + $objOrder = new Order($lastOrder['id_order']); + $objOrder->total_paid_real -= $totalAdvancePayment; + $objOrder->save(); + foreach ($orders as $order) { + $objOrderPaymentDetail = new OrderPaymentDetail(); + $objOrderPaymentDetail->id_order_payment = $payment['id_order_payment']; + $objOrderPaymentDetail->id_order = $order['id_order']; + $objOrderPaymentDetail->amount = $order['advance_paid_amount']; + $objOrderPaymentDetail->save(); + + $objOrder = new Order($order['id_order']); + $objOrder->total_paid_real += $objOrder->advance_paid_amount; + $objOrder->save(); + + } + } + } else { + foreach ($orders as $order) { + $ordersPayment = Db::getInstance()->getRow(' + SELECT `total_paid_real`, IFNULL(SUM(`amount`), 0) as payment_amount + FROM `'._DB_PREFIX_.'orders` o + LEFT JOIN `'._DB_PREFIX_.'order_payment_detail` opd + ON (opd.`id_order` = o.`id_order`) + WHERE o.`id_order` = '.(int) $order['id_order'].' + GROUP BY o.`id_order`' + ); + if ($ordersPayment['total_paid_real'] > $ordersPayment['payment_amount']) { + $objOrderPaymentDetail = new OrderPaymentDetail(); + $objOrderPaymentDetail->id_order_payment = $payment['id_order_payment']; + $objOrderPaymentDetail->id_order = $order['id_order']; + $objOrderPaymentDetail->amount = $ordersPayment['total_paid_real'] - $ordersPayment['payment_amount']; + $objOrderPaymentDetail->save(); + break; + } + } + } + } + } + } + } + } + return true; +} + diff --git a/install/upgrade/sql/1.5.0.sql b/install/upgrade/sql/1.5.0.sql index 9b050115a..5a8ba5514 100644 --- a/install/upgrade/sql/1.5.0.sql +++ b/install/upgrade/sql/1.5.0.sql @@ -56,9 +56,9 @@ SELECT '1', `id_lang`, 'Waiting for confirmation', 'order_refund_waiting_custome INSERT INTO `PREFIX_order_return_state_lang` (`id_order_return_state`, `id_lang`, `name`, `customer_template`, `admin_template`) SELECT '2', `id_lang`, 'Request received', 'order_refund_received_customer', 'order_refund_received_admin' FROM `PREFIX_lang`; INSERT INTO `PREFIX_order_return_state_lang` (`id_order_return_state`, `id_lang`, `name`, `customer_template`, `admin_template`) -SELECT '3', `id_lang`, 'Denied', 'order_refund_denied_customer', 'order_refund_denied_admin' FROM `PREFIX_lang`; +SELECT '3', `id_lang`, 'Refund denied', 'order_refund_denied_customer', 'order_refund_denied_admin' FROM `PREFIX_lang`; INSERT INTO `PREFIX_order_return_state_lang` (`id_order_return_state`, `id_lang`, `name`, `customer_template`, `admin_template`) -SELECT '4', `id_lang`, 'Completed', 'order_refund_completed_customer', 'order_refund_completed_admin' FROM `PREFIX_lang`; +SELECT '4', `id_lang`, 'Refund completed', 'order_refund_completed_customer', 'order_refund_completed_admin' FROM `PREFIX_lang`; ALTER TABLE `PREFIX_order_slip_detail` diff --git a/install/upgrade/sql/1.6.0.0.sql b/install/upgrade/sql/1.6.0.0.sql new file mode 100644 index 000000000..8a0b2fd29 --- /dev/null +++ b/install/upgrade/sql/1.6.0.0.sql @@ -0,0 +1,222 @@ +SET NAMES 'utf8'; + +ALTER TABLE `PREFIX_address` ADD `id_hotel` int(10) unsigned NOT NULL DEFAULT '0' AFTER `id_warehouse`; + +CREATE TABLE `PREFIX_order_customer_guest_detail` ( + `id_order_customer_guest_detail` int(10) unsigned NOT NULL auto_increment, + `id_order` int(10) unsigned NOT NULL, + `id_gender` int(10) unsigned NOT NULL, + `firstname` varchar(32) NOT NULL, + `lastname` varchar(32) NOT NULL, + `email` varchar(128) NOT NULL, + `phone` varchar(32) DEFAULT NULL, + `date_add` datetime NOT NULL, + `date_upd` datetime NOT NULL, + PRIMARY KEY (`id_order_customer_guest_detail`) +) ENGINE=ENGINE_TYPE DEFAULT CHARSET=utf8; + +CREATE TABLE `PREFIX_cart_customer_guest_detail` ( + `id_customer_guest_detail` int(10) unsigned NOT NULL auto_increment, + `id_cart` int(10) unsigned NOT NULL, + `id_gender` int(10) unsigned NOT NULL, + `firstname` varchar(32) NOT NULL, + `lastname` varchar(32) NOT NULL, + `email` varchar(128) NOT NULL, + `phone` varchar(32) DEFAULT NULL, + `date_add` datetime NOT NULL, + `date_upd` datetime NOT NULL, + PRIMARY KEY (`id_customer_guest_detail`) +) ENGINE=ENGINE_TYPE DEFAULT CHARSET=utf8; + +ALTER TABLE `PREFIX_image_type` ADD `hotels` tinyint(1) NOT NULL DEFAULT '1' AFTER `categories`; +UPDATE `PREFIX_image_type` SET `hotels` = '1' WHERE `name` IN ("small_default", "medium_default", "large_default"); + +ALTER TABLE `PREFIX_orders` +ADD `id_address_tax` int(10) unsigned NOT NULL AFTER `id_address_invoice`, +ADD `payment_type` int(10) unsigned NOT NULL AFTER `payment`, +ADD `with_occupancy` tinyint(1) NOT NULL DEFAULT '0' AFTER `advance_paid_amount`; + +UPDATE `PREFIX_orders` +set `id_address_tax` = `id_address_invoice`; + +ALTER TABLE `PREFIX_order_detail` +ADD `is_booking_product` tinyint(1) NOT NULL DEFAULT '0' AFTER `product_quantity_discount`, +ADD `product_service_type` tinyint(1) NOT NULL DEFAULT '1' AFTER `is_booking_product`, +ADD `product_auto_add` tinyint(1) NOT NULL DEFAULT '0' AFTER `product_service_type`, +ADD `product_price_addition_type` tinyint(1) NOT NULL DEFAULT '0' AFTER `product_auto_add`, +ADD `product_allow_multiple_quantity` tinyint(1) unsigned NOT NULL DEFAULT '1' AFTER `product_price_addition_type`, +ADD `product_price_calculation_method` tinyint(1) unsigned NOT NULL DEFAULT '1' AFTER `product_allow_multiple_quantity`; + +UPDATE `PREFIX_order_detail` +set `is_booking_product` = 1; + +ALTER TABLE `PREFIX_order_return` +ADD`id_return_type` tinyint(1) unsigned NOT NULL DEFAULT '0' AFTER `by_admin`, +ADD`return_type` tinyint(1) unsigned NOT NULL DEFAULT '0' AFTER `id_return_type`; + +ALTER TABLE `PREFIX_order_slip` +ADD `redeem_status` TINYINT(1) NOT NULL DEFAULT '0' AFTER `partial`, +ADD `id_cart_rule` int(10) unsigned NOT NULL DEFAULT '0' AFTER `redeem_status`; +UPDATE `PREFIX_order_slip` +set `redeem_status` = 1; + +ALTER TABLE `PREFIX_order_payment` ADD `payment_type` INT UNSIGNED NOT NULL AFTER `payment_method`; +UPDATE `PREFIX_order_payment` op +INNER JOIN `PREFIX_orders` o ON (op.`order_reference` = o.`reference`) +SET o.`payment_type` = "1", op.`payment_type` = "1" +WHERE o.`module` IS NOT NULL; +UPDATE `PREFIX_order_payment` op +INNER JOIN `PREFIX_orders` o ON (op.`order_reference` = o.`reference`) +SET o.`payment_type` = "1", op.`payment_type` = "2" +WHERE o.`module` IS NULL; + +CREATE TABLE `PREFIX_order_payment_detail` ( + `id_order_payment_detail` INT(10) unsigned NOT NULL auto_increment, + `id_order_payment` INT(10) unsigned NOT NULL, + `id_order` INT(10) unsigned NOT NULL, + `amount` DECIMAL(10,2) NOT NULL, + `date_add` DATETIME NOT NULL, + PRIMARY KEY (`id_order_payment_detail`) +) ENGINE=ENGINE_TYPE DEFAULT CHARSET=utf8; + +ALTER TABLE `PREFIX_product` +ADD `allow_multiple_quantity` tinyint(1) unsigned NOT NULL DEFAULT '1' AFTER `minimal_quantity`, +ADD `max_quantity` int(10) unsigned NOT NULL DEFAULT '1' AFTER `allow_multiple_quantity`, +ADD `price_calculation_method` tinyint(1) unsigned NOT NULL DEFAULT '1' AFTER `max_quantity`, +ADD `auto_add_to_cart` tinyint(1) NOT NULL DEFAULT '0' AFTER `available_for_order`, +ADD `price_addition_type` tinyint(1) NOT NULL DEFAULT '1' AFTER `auto_add_to_cart`, +ADD `show_at_front` tinyint(1) NOT NULL DEFAULT '1' AFTER `price_addition_type`, +ADD `service_product_type` tinyint(1) NOT NULL DEFAULT '1' AFTER `show_at_front`, +ADD `price_display_method` tinyint(1) NOT NULL DEFAULT '1' AFTER `service_product_type`, +ADD `booking_product` tinyint(1) NOT NULL DEFAULT '1' AFTER `is_virtual`; + +ALTER TABLE `PREFIX_product_shop` +ADD `allow_multiple_quantity` tinyint(1) unsigned NOT NULL DEFAULT '1' AFTER `minimal_quantity`, +ADD `max_quantity` int(10) unsigned NOT NULL DEFAULT '1' AFTER `allow_multiple_quantity`, +ADD `price_calculation_method` tinyint(1) unsigned NOT NULL DEFAULT '1' AFTER `max_quantity`, +ADD `auto_add_to_cart` tinyint(1) NOT NULL DEFAULT '0' AFTER `available_for_order`, +ADD `price_addition_type` tinyint(1) NOT NULL DEFAULT '1' AFTER `auto_add_to_cart`, +ADD `show_at_front` tinyint(1) NOT NULL DEFAULT '1' AFTER `price_addition_type`, +ADD `price_display_method` tinyint(1) NOT NULL DEFAULT '1' AFTER `show_at_front`; + +ALTER TABLE `PREFIX_order_invoice_payment` ADD `id_order_payment_detail` int(11) unsigned NOT NULL AFTER `id_order_payment`; + +CREATE TABLE `PREFIX_maintenance_access` ( + `id_maintenance_access` int(11) unsigned NOT NULL AUTO_INCREMENT, + `ip_address` varchar(50) NOT NULL, + `email` varchar(128) NOT NULL, + `date_add` datetime NOT NULL, + PRIMARY KEY (`id_maintenance_access`) +) ENGINE=ENGINE_TYPE DEFAULT CHARSET=utf8; + +INSERT INTO `PREFIX_configuration` (`name`, `value`, `date_add`, `date_upd`) VALUES + ('PS_HOTEL_IMAGES_PER_PAGE', '9', NOW(), NOW()), + ('PS_COOKIE_SAMESITE', 'Lax', NOW(), NOW()), + ('HOTEL_CHECKUP_DESCRIPTIONS_LT', '100', NOW(), NOW()), + ('HOTEL_CHECKUP_DESCRIPTIONS_GT', '400', NOW(), NOW()), + ('HOTEL_CHECKUP_IMAGES_LT', '1', NOW(), NOW()), + ('HOTEL_CHECKUP_IMAGES_GT', '2', NOW(), NOW()), + ('HOTEL_CHECKUP_ORDERS_LT', '1', NOW(), NOW()), + ('HOTEL_CHECKUP_ORDERS_GT', '2', NOW(), NOW()), + ('HOTEL_CHECKUP_TOTAL_ROOMS_LT', '1', NOW(), NOW()), + ('HOTEL_CHECKUP_TOTAL_ROOMS_GT', '3', NOW(), NOW()), + ('ROOM_TYPE_CHECKUP_DESCRIPTIONS_LT', '100', NOW(), NOW()), + ('ROOM_TYPE_CHECKUP_DESCRIPTIONS_GT', '400', NOW(), NOW()), + ('ROOM_TYPE_CHECKUP_IMAGES_LT', '1', NOW(), NOW()), + ('ROOM_TYPE_CHECKUP_IMAGES_GT', '2', NOW(), NOW()), + ('ROOM_TYPE_CHECKUP_ORDERS_LT', '1', NOW(), NOW()), + ('ROOM_TYPE_CHECKUP_ORDERS_GT', '2', NOW(), NOW()), + ('ROOM_TYPE_CHECKUP_TOTAL_ROOMS_LT', '1', NOW(), NOW()), + ('ROOM_TYPE_CHECKUP_TOTAL_ROOMS_GT', '3', NOW(), NOW()), + ('SERVICE_CHECKUP_DESCRIPTIONS_SHORT_LT', '50', NOW(), NOW()), + ('SERVICE_CHECKUP_DESCRIPTIONS_SHORT_GT', '150', NOW(), NOW()), + ('SERVICE_CHECKUP_IMAGES_LT', '1', NOW(), NOW()), + ('SERVICE_CHECKUP_IMAGES_GT', '2', NOW(), NOW()), + ('SERVICE_CHECKUP_ORDERS_LT', '1', NOW(), NOW()), + ('SERVICE_CHECKUP_ORDERS_GT', '2', NOW(), NOW()), + ('PS_SERVICE_PRODUCT_CATEGORY_FILTER', '1', NOW(), NOW()); + + +CREATE PROCEDURE qlo_move_product_comment_to_review() +BEGIN + IF (SELECT COUNT(table_name) + FROM + information_schema.TABLES as table_name + WHERE + TABLE_SCHEMA LIKE (SELECT DATABASE()) AND + TABLE_TYPE LIKE 'BASE TABLE' AND + TABLE_NAME = 'qlo_product_comment') + THEN + CREATE TABLE IF NOT EXISTS `PREFIX_qhr_hotel_review` ( + `id_hotel_review` INT(10) NOT NULL AUTO_INCREMENT, + `id_hotel` INT(10) NOT NULL, + `id_order` INT(10) NOT NULL, + `rating` FLOAT UNSIGNED NOT NULL, + `subject` VARCHAR(255) NOT NULL, + `description` TEXT NOT NULL, + `status_abusive` TINYINT(1) DEFAULT 0, + `status` TINYINT(1) DEFAULT 0, + `date_add` DATETIME NOT NULL, + `date_upd` DATETIME NOT NULL, + PRIMARY KEY (`id_hotel_review`) + ) ENGINE=ENGINE_TYPE DEFAULT CHARSET=utf8; CREATE TABLE IF NOT EXISTS `PREFIX_qhr_category` ( + `id_category` INT(10) NOT NULL AUTO_INCREMENT, + `active` TINYINT(1) DEFAULT 1, + `date_add` DATETIME NOT NULL, + `date_upd` DATETIME NOT NULL, + PRIMARY KEY (`id_category`) + ) ENGINE=ENGINE_TYPE DEFAULT CHARSET=utf8; CREATE TABLE IF NOT EXISTS `PREFIX_qhr_category_lang` ( + `id_category` INT(10) NOT NULL, + `id_lang` INT(10) NOT NULL, + `name` VARCHAR(255) NOT NULL, + PRIMARY KEY (`id_category`, `id_lang`) + ) ENGINE=ENGINE_TYPE DEFAULT CHARSET=utf8; CREATE TABLE IF NOT EXISTS `PREFIX_qhr_review_category_rating` ( + `id_hotel_review` INT(10) NOT NULL, + `id_category` INT(10) NOT NULL, + `rating` FLOAT UNSIGNED NOT NULL, + PRIMARY KEY (`id_hotel_review`, `id_category`) + ) ENGINE=ENGINE_TYPE DEFAULT CHARSET=utf8; CREATE TABLE IF NOT EXISTS `PREFIX_qhr_review_usefulness` ( + `id_hotel_review` INT(10) NOT NULL, + `id_customer` INT(10) NOT NULL, + PRIMARY KEY (`id_hotel_review`, `id_customer`) + ) ENGINE=ENGINE_TYPE DEFAULT CHARSET=utf8; CREATE TABLE IF NOT EXISTS `PREFIX_qhr_review_report` ( + `id_hotel_review` INT(10) NOT NULL, + `id_customer` INT(10) NOT NULL, + PRIMARY KEY (`id_hotel_review`, `id_customer`) + ) ENGINE=ENGINE_TYPE DEFAULT CHARSET=utf8; CREATE TABLE IF NOT EXISTS `PREFIX_qhr_review_reply` ( + `id_review_reply` INT(10) NOT NULL AUTO_INCREMENT, + `id_hotel_review` INT(10) NOT NULL, + `id_employee` INT(10) NOT NULL DEFAULT 0, + `message` TEXT NOT NULL, + `date_add` DATETIME NOT NULL, + PRIMARY KEY (`id_review_reply`) + ) ENGINE=ENGINE_TYPE DEFAULT CHARSET=utf8; INSERT INTO `PREFIX_qhr_hotel_review` (`id_hotel_review`, `id_hotel`, `id_order`, `rating`, `subject`, `description`, `status_abusive`, `status`, `date_add`, `date_upd`) + SELECT pc.`id_product_comment`, hrt.`id_hotel`, 0, pc.`grade`, pc.`title`, pc.`content`, 0, IF(pc.`deleted`, 2, IF(pc.`validate`, 3, 1)), NOW(), NOW() + FROM `PREFIX_product_comment` pc + INNER JOIN `PREFIX_htl_room_type` hrt ON (pc.`id_product` = hrt.`id_product`); INSERT INTO `PREFIX_qhr_category` (`id_category`, `active`, `date_add`, `date_upd`) + SELECT `id_product_comment_criterion`, `active`, NOW(), NOW() + FROM `PREFIX_product_comment_criterion`; INSERT INTO `PREFIX_qhr_category_lang` (`id_category`, `id_lang`, `name`) + SELECT pcc.`id_product_comment_criterion`, `id_lang`, `name` + FROM `PREFIX_product_comment_criterion` pcc + INNER JOIN `PREFIX_product_comment_criterion_lang` pccl ON (pccl.`id_product_comment_criterion` = pcc.`id_product_comment_criterion`); INSERT INTO `PREFIX_qhr_review_category_rating` (`id_hotel_review`, `id_category`, `rating`) + SELECT `id_product_comment`, `id_product_comment_criterion`, `grade` + FROM `PREFIX_product_comment_grade`; INSERT INTO `PREFIX_qhr_review_usefulness` (`id_hotel_review`, `id_customer`) + SELECT `id_product_comment`, `id_customer` + FROM `PREFIX_product_comment_usefulness` WHERE `usefulness` = 1; INSERT INTO `PREFIX_qhr_review_report` (`id_hotel_review`, `id_customer`) + SELECT `id_product_comment`, `id_customer` + FROM `PREFIX_product_comment_report`; END IF; END; + +call qlo_move_product_comment_to_review; + +DROP PROCEDURE qlo_move_product_comment_to_review; + + +/* PHP:add_new_tabs_160(); */; +/* PHP:add_new_categores_160(); */; +/* PHP:move_hotel_categoryes_to_location(); */; +/* PHP:move_hotel_address_to_address_table(); */; +/* PHP:add_new_order_refund_states_160(); */; +/* PHP:update_order_payment_detail_160(); */; + + + diff --git a/modules/blockcurrencies/upgrade/index.php b/modules/blockcurrencies/upgrade/index.php new file mode 100644 index 000000000..a2a4c7caf --- /dev/null +++ b/modules/blockcurrencies/upgrade/index.php @@ -0,0 +1,29 @@ + +* @copyright 2010-2023 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); +header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); + +header('Cache-Control: no-store, no-cache, must-revalidate'); +header('Cache-Control: post-check=0, pre-check=0', false); +header('Pragma: no-cache'); + +header('Location: ../../../'); +exit; diff --git a/modules/blockcurrencies/upgrade/upgrade-1.1.0.php b/modules/blockcurrencies/upgrade/upgrade-1.1.0.php new file mode 100644 index 000000000..9ea699209 --- /dev/null +++ b/modules/blockcurrencies/upgrade/upgrade-1.1.0.php @@ -0,0 +1,49 @@ + +* @copyright 2010-2022 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +if (!defined('_PS_VERSION_')) + exit; + +function upgrade_module_1_1_0($module) +{ + $objUpgrade = new UpgradeBlockCurrencies110($module); + return $objUpgrade->initUpgrade(); +} + +class UpgradeBlockCurrencies110 +{ + public function __construct($module) + { + $this->module = $module; + } + + public function initUpgrade() + { + if (!$this->module->unregisterHook('displayFooterMostLeftBlock') + || !$this->module->unregisterHook('displayHeader') + || !$this->module->registerHook('actionFrontControllerSetMedia') + || !$this->module->registerHook('displayNav') + || !$this->module->registerHook('displayExternalNavigationHook') + ) { + return false; + } + return true; + } +} diff --git a/modules/blocklanguages/upgrade/index.php b/modules/blocklanguages/upgrade/index.php new file mode 100644 index 000000000..a2a4c7caf --- /dev/null +++ b/modules/blocklanguages/upgrade/index.php @@ -0,0 +1,29 @@ + +* @copyright 2010-2023 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); +header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); + +header('Cache-Control: no-store, no-cache, must-revalidate'); +header('Cache-Control: post-check=0, pre-check=0', false); +header('Pragma: no-cache'); + +header('Location: ../../../'); +exit; diff --git a/modules/blocklanguages/upgrade/upgrade-1.6.0.php b/modules/blocklanguages/upgrade/upgrade-1.6.0.php new file mode 100644 index 000000000..b959a7415 --- /dev/null +++ b/modules/blocklanguages/upgrade/upgrade-1.6.0.php @@ -0,0 +1,49 @@ + +* @copyright 2010-2022 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +if (!defined('_PS_VERSION_')) + exit; + +function upgrade_module_1_6_0($module) +{ + $objUpgrade = new UpgradeBlockLanguages160($module); + return $objUpgrade->initUpgrade(); +} + +class UpgradeBlockLanguages160 +{ + public function __construct($module) + { + $this->module = $module; + } + + public function initUpgrade() + { + if (!$this->module->unregisterHook('displayFooterMostLeftBlock') + || !$this->module->unregisterHook('displayHeader') + || !$this->module->registerHook('actionFrontControllerSetMedia') + || !$this->module->registerHook('displayNav') + || !$this->module->registerHook('displayExternalNavigationHook') + ) { + return false; + } + return true; + } +} diff --git a/modules/blocknavigationmenu/upgrade/upgrade-1.1.2.php b/modules/blocknavigationmenu/upgrade/upgrade-1.1.2.php new file mode 100644 index 000000000..b83ec8442 --- /dev/null +++ b/modules/blocknavigationmenu/upgrade/upgrade-1.1.2.php @@ -0,0 +1,42 @@ + +* @copyright 2010-2022 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +if (!defined('_PS_VERSION_')) + exit; + +function upgrade_module_1_1_2($module) +{ + $objUpgrade = new upgradeBlockNavigationMenu112($module); + return $objUpgrade->initUpgrade(); +} + +class upgradeBlockNavigationMenu112 +{ + public function __construct($module) + { + $this->module = $module; + } + + public function initUpgrade() + { + return $this->module->unregisterHook('displayAddModuleSettingLink'); + + } +} diff --git a/modules/dashguestcycle/upgrade/index.php b/modules/dashguestcycle/upgrade/index.php new file mode 100644 index 000000000..a2a4c7caf --- /dev/null +++ b/modules/dashguestcycle/upgrade/index.php @@ -0,0 +1,29 @@ + +* @copyright 2010-2023 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); +header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); + +header('Cache-Control: no-store, no-cache, must-revalidate'); +header('Cache-Control: post-check=0, pre-check=0', false); +header('Pragma: no-cache'); + +header('Location: ../../../'); +exit; diff --git a/modules/dashguestcycle/upgrade/upgrade-1.0.1.php b/modules/dashguestcycle/upgrade/upgrade-1.0.1.php new file mode 100644 index 000000000..4e6be25f3 --- /dev/null +++ b/modules/dashguestcycle/upgrade/upgrade-1.0.1.php @@ -0,0 +1,46 @@ + +* @copyright 2010-2022 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +if (!defined('_PS_VERSION_')) + exit; + +function upgrade_module_1_0_1($module) +{ + $objUpgrade = new UpgradeDashGuestCycle101($module); + return $objUpgrade->initUpgrade(); +} + +class UpgradeDashGuestCycle101 +{ + public function __construct($module) + { + $this->module = $module; + } + + public function initUpgrade() + { + if (!$this->module->registerHook('dashboardZoneTwo')) { + return false; + } + $idHook = Hook::getIdByName('dashboardZoneTwo'); + $this->module->updatePosition($idHook, 0, 1); + return true; + } +} diff --git a/modules/dashoccupancy/upgrade/index.php b/modules/dashoccupancy/upgrade/index.php new file mode 100644 index 000000000..a2a4c7caf --- /dev/null +++ b/modules/dashoccupancy/upgrade/index.php @@ -0,0 +1,29 @@ + +* @copyright 2010-2023 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); +header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); + +header('Cache-Control: no-store, no-cache, must-revalidate'); +header('Cache-Control: post-check=0, pre-check=0', false); +header('Pragma: no-cache'); + +header('Location: ../../../'); +exit; diff --git a/modules/dashoccupancy/upgrade/upgrade-1.0.1.php b/modules/dashoccupancy/upgrade/upgrade-1.0.1.php new file mode 100644 index 000000000..ba27b1f30 --- /dev/null +++ b/modules/dashoccupancy/upgrade/upgrade-1.0.1.php @@ -0,0 +1,46 @@ + +* @copyright 2010-2022 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +if (!defined('_PS_VERSION_')) + exit; + +function upgrade_module_1_0_1($module) +{ + $objUpgrade = new UpgradeDashOccupancy101($module); + return $objUpgrade->initUpgrade(); +} + +class UpgradeDashOccupancy101 +{ + public function __construct($module) + { + $this->module = $module; + } + + public function initUpgrade() + { + if (!$this->module->registerHook('dashboardZoneOne') + || !$this->module->unregisterHook('dashboardZoneTwo') + ) { + return false; + } + return true; + } +} diff --git a/modules/hotelreservationsystem/upgrade/upgrade-1.5.0.php b/modules/hotelreservationsystem/upgrade/upgrade-1.5.0.php new file mode 100644 index 000000000..ed4cbd45a --- /dev/null +++ b/modules/hotelreservationsystem/upgrade/upgrade-1.5.0.php @@ -0,0 +1,401 @@ + +* @copyright 2010-2023 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +if (!defined('_PS_VERSION_')) + exit; + +function upgrade_module_1_5_0($module) +{ + $objUpgrade = new UpgradeHotelreservationSystem150($module); + return $objUpgrade->initUpgrade(); +} + +class UpgradeHotelreservationSystem150 +{ + public function __construct($module) + { + $this->module = $module; + } + + public function initUpgrade() + { + if (!$this->moveHotelImagesToNewDirectory() + || !$this->updateTables() + || !$this->deleteUnusedTables() + || !$this->updateDefautData() + || !$this->updateHooks() + + ) { + return false; + } + return true; + } + + public function updateTables() + { + if ($sql = $this->getModuleSql()) { + foreach ($sql as $query) { + if ($query) { + if (!Db::getInstance()->execute(trim($query))) { + return false; + } + } + } + } + return true; + } + + public function deleteUnusedTables() + { + return Db::getInstance()->execute( + "DROP TABLE IF EXISTS `"._DB_PREFIX_."htl_room_allotment_type`;" + ); + } + + public function updateDefautData() + { + if (!$this->addSettingsLinksData() + || !$this->updateTabs() + || !$this->updateDefaultConfiguration() + ) { + return false; + } + return true; + } + + public function updateHooks() + { + if (!$this->module->unregisterHook('actionValidateOrder') + || !$this->module->unregisterHook('actionAdminControllerSetMedia') + || !$this->module->unregisterHook('displayAdminProductsExtra') + || !$this->module->unregisterHook('actionProductUpdate') + || !$this->module->registerHook('displayLeftColumn') + || !$this->module->registerHook('actionCartSummary') + ) { + return false; + } + + return true; + } + + public function addSettingsLinksData() + { + $tabs = array( + array ('icon' => 'icon-cogs', + 'link' => 'index.php?controller=AdminHotelGeneralSettings', + 'new_window' => 0, + 'unremovable' => 1, + 'active' => 1, + 'name' => 'General Settings', + 'hint' => 'Configure Your hotel general gettings using this option.', + ), + array ('icon' => 'icon-dollar', + 'link' => 'index.php?controller=AdminHotelFeaturePricesSettings', + 'new_window' => 0, + 'unremovable' => 1, + 'active' => 1, + 'name' => 'Advanced Price Rules', + 'hint' => 'Here set Advanced price rules for specific dates.', + ), + array ('icon' => 'icon-plus-square', + 'link' => 'index.php?controller=AdminRoomTypeGlobalDemand', + 'new_window' => 0, + 'unremovable' => 1, + 'active' => 1, + 'name' => 'Additional Facilities', + 'hint' => 'Here create Additional facilities and their prices for room types.', + ), + array ('icon' => 'icon-file-text', + 'link' => 'index.php?controller=AdminAboutHotelBlockSetting', + 'new_window' => 0, + 'unremovable' => 0, + 'active' => 1, + 'name' => 'Hotel Interior Block', + 'hint' => 'Configure Hotel Interior block. You can display hotel interior images using this block. This block will be displayed on home page.', + ), + array ('icon' => 'icon-th-list', + 'link' => 'index.php?controller=AdminFeaturesModuleSetting', + 'new_window' => 0, + 'unremovable' => 0, + 'active' => 1, + 'name' => 'Hotel Amenities Block', + 'hint' => 'Configure Hotels Amenities settings. You can display hotel amenities images using this block. This block will be displayed on home page.', + ) + ); + + $Languages = Language::getLanguages(true); + $res = true; + foreach ($tabs as $tab) { + $objHotelSettingsLink = new HotelSettingsLink(); + $objHotelSettingsLink->icon = $tab['icon']; + $objHotelSettingsLink->link = $tab['link']; + $objHotelSettingsLink->new_window = $tab['new_window']; + $objHotelSettingsLink->position = $objHotelSettingsLink->getHigherPosition(); + $objHotelSettingsLink->unremovable = $tab['unremovable']; + $objHotelSettingsLink->active = $tab['active']; + foreach($Languages as $lang) { + $objHotelSettingsLink->name[$lang['id_lang']] = $tab['name']; + $objHotelSettingsLink->hint[$lang['id_lang']] = $tab['hint']; + } + $res &= $objHotelSettingsLink->save(); + } + + return $res; + } + + public function updateTabs() + { + $toDeleteTabs = array('AdminOrderRestrictSettings'); + if (!empty($toDeleteTabs)) { + foreach ($toDeleteTabs as $moduleTab) { + $id_tab = Tab::getIdFromClassName($moduleTab); + $objTab = new Tab($id_tab); + $objTab->delete(); + } + } + + $this->module->installTab('AdminBookingDocument', 'Booking Documents', false, false); + + $updateTabs = array( + 'AdminHotelFeaturePricesSettings' => array('name' => 'Advanced Price Rules'), + 'AdminRoomTypeGlobalDemand' => array('name' => 'Additional Demand Configuration') + ); + $Languages = Language::getLanguages(true); + foreach ($updateTabs as $key => $tab) { + $id_tab = Tab::getIdFromClassName($key); + $objTab = new Tab($id_tab); + foreach($Languages as $lang) { + $objTab->name[$lang['id_lang']] = $tab['name']; + } + $objTab->save(); + } + + return true; + } + + public function updateDefaultConfiguration() + { + Configuration::updateValue('WK_GLOBAL_CHILD_MAX_AGE', 15); + Configuration::updateValue('WK_GLOBAL_MAX_CHILD_IN_ROOM', 3); + Configuration::updateValue('GLOBAL_PREPARATION_TIME', 0); + + // Search Fields + Configuration::updateValue('PS_FRONT_SEARCH_TYPE', HotelBookingDetail::SEARCH_TYPE_OWS); + Configuration::updateValue('PS_FRONT_OWS_SEARCH_ALGO_TYPE', HotelBookingDetail::SEARCH_EXACT_ROOM_TYPE_ALGO); + Configuration::updateValue('PS_FRONT_ROOM_UNIT_SELECTION_TYPE', HotelBookingDetail::PS_ROOM_UNIT_SELECTION_TYPE_OCCUPANCY); + Configuration::updateValue('PS_BACKOFFICE_SEARCH_TYPE', HotelBookingDetail::SEARCH_TYPE_OWS); + Configuration::updateValue('PS_BACKOFFICE_OWS_SEARCH_ALGO_TYPE', HotelBookingDetail::SEARCH_ALL_ROOM_TYPE_ALGO); + Configuration::updateValue('PS_BACKOFFICE_ROOM_BOOKING_TYPE', HotelBookingDetail::PS_ROOM_UNIT_SELECTION_TYPE_OCCUPANCY); + Configuration::updateValue('PS_LOS_RESTRICTION_BO', 0); + + return true; + } + + public function moveHotelImagesToNewDirectory() + { + $images = Db::getInstance()->executeS('SELECT `id`, `id_hotel`, `hotel_image_id` FROM `'._DB_PREFIX_.'htl_image`'); + foreach($images as $image) { + if (!file_exists(_PS_HOTEL_IMG_DIR_.$image['id_hotel'].'/')) { + // Apparently sometimes mkdir cannot set the rights, and sometimes chmod can't. Trying both. + $success = @mkdir(_PS_HOTEL_IMG_DIR_.$image['id_hotel'].'/', 0755, true); + $chmod = @chmod(_PS_HOTEL_IMG_DIR_.$image['id_hotel'].'/', 0755); + + // Create an index.php file in the new folder + if (($success || $chmod) + && !file_exists(_PS_HOTEL_IMG_DIR_.$image['id_hotel'].'/'.'index.php') + && file_exists(_PS_HOTEL_IMG_DIR_.'index.php')) { + @copy(_PS_HOTEL_IMG_DIR_.'index.php', _PS_HOTEL_IMG_DIR_.$image['id_hotel'].'/'.'index.php'); + } + } + // move image from old directory to new directory + copy( + _PS_HOTEL_IMG_DIR_.$image['hotel_image_id'].'.'.'jpg', + _PS_HOTEL_IMG_DIR_.$image['id_hotel'].'/'.$image['id'].'.'.'jpg' + ); + @unlink(_PS_HOTEL_IMG_DIR_.$image['hotel_image_id'].'.'.'jpg'); + } + return true; + } + + public function getModuleSql() + { + return array ( + "ALTER TABLE `"._DB_PREFIX_."htl_room_type` + CHANGE `adult` `adults` smallint(6) NOT NULL DEFAULT '2', + ADD `max_adults` smallint(6) NOT NULL DEFAULT '2' AFTER `children`, + ADD `max_children` smallint(6) NOT NULL DEFAULT '0' AFTER `max_adults`, + ADD `max_guests` smallint(6) NOT NULL DEFAULT '2' AFTER `max_children`, + ADD `min_los` smallint(6) NOT NULL DEFAULT '1' AFTER `max_guests`, + ADD `max_los` smallint(6) NOT NULL DEFAULT '0' AFTER `min_los`;", + + "UPDATE `"._DB_PREFIX_."htl_room_type` + SET `max_adults` = `adults`, + `max_children` = `children`, + `max_guests` = adults + children;", + + "ALTER TABLE `"._DB_PREFIX_."htl_branch_info` + DROP COLUMN `phone`, + DROP COLUMN `city`, + DROP COLUMN `state_id`, + DROP COLUMN `country_id`, + DROP COLUMN `zipcode`, + DROP COLUMN `address`;", + + "ALTER TABLE `"._DB_PREFIX_."htl_image` + DROP COLUMN `hotel_image_id`;", + + "ALTER TABLE `"._DB_PREFIX_."htl_cart_booking_data` + ADD `adults` smallint(6) NOT NULL AFTER `date_to`, + ADD `children` smallint(6) NOT NULL AFTER `adults`, + ADD `child_ages` text NOT NULL AFTER `children`;", + + "UPDATE `"._DB_PREFIX_."htl_cart_booking_data` hcbd + INNER JOIN `"._DB_PREFIX_."htl_room_type` hrt ON (hcbd.`id_product` = hrt.`id_product`) + SET hcbd.`adults` = hrt.`adults`, + hcbd.`children` = hrt.`children`, + hcbd.`child_ages` = \"".json_encode(array())."\";", + + "ALTER TABLE `"._DB_PREFIX_."htl_booking_detail` + CHANGE `adult` `adults` smallint(6) NOT NULL DEFAULT '0', + ADD `child_ages` text NOT NULL AFTER `children`, + ADD `is_cancelled` tinyint(1) NOT NULL DEFAULT '0' AFTER `is_refunded`;", + + "UPDATE `"._DB_PREFIX_."htl_booking_detail` + SET `child_ages` = \"".json_encode(array())."\";", + + "CREATE TABLE IF NOT EXISTS `"._DB_PREFIX_."htl_booking_document` ( + `id_htl_booking_document` int(11) NOT NULL AUTO_INCREMENT, + `id_htl_booking` int(11) NOT NULL, + `title` varchar(32) NOT NULL DEFAULT '', + `file_type` tinyint(1) NOT NULL DEFAULT '0', + `file_name` varchar(8) NOT NULL DEFAULT '', + `date_add` datetime NOT NULL, + PRIMARY KEY (`id_htl_booking_document`) + ) ENGINE="._MYSQL_ENGINE_." DEFAULT CHARSET=utf8 AUTO_INCREMENT=1;", + + "ALTER TABLE `"._DB_PREFIX_."htl_order_restrict_date` + ADD `use_global_max_order_date` tinyint(1) NOT NULL AFTER `id_hotel`, + CHANGE `max_order_date` `max_order_date` date NOT NULL, + ADD `use_global_preparation_time` tinyint(1) NOT NULL AFTER `max_order_date`, + ADD `preparation_time` int(11) NOT NULL AFTER `use_global_preparation_time`;", + + "UPDATE `"._DB_PREFIX_."htl_order_restrict_date` + SET `use_global_max_order_date` = 1", + + "ALTER TABLE `"._DB_PREFIX_."htl_room_type_feature_pricing` + ADD `id_cart` int(11) NOT NULL DEFAULT '0' AFTER `id_product`, + ADD `id_guest` int(11) NOT NULL DEFAULT '0' AFTER `id_cart`, + ADD `id_room` int(11) NOT NULL DEFAULT '0' AFTER `id_guest`;", + + "CREATE TABLE `"._DB_PREFIX_."htl_room_type_service_product` ( + `id_room_type_service_product` int(11) UNSIGNED NOT NULL AUTO_INCREMENT, + `id_product` int(11) UNSIGNED NOT NULL, + `position` smallint(2) unsigned NOT NULL DEFAULT '0', + `id_element` int(11) unsigned NOT NULL, + `element_type` tinyint(11) unsigned NOT NULL, + PRIMARY KEY (`id_room_type_service_product`), + KEY `id_product` (`id_product`) + ) ENGINE="._MYSQL_ENGINE_." DEFAULT CHARSET=utf8 AUTO_INCREMENT=1;", + + "CREATE TABLE `"._DB_PREFIX_."htl_room_type_service_product_price` ( + `id_room_type_service_product_price` int(11) UNSIGNED NOT NULL AUTO_INCREMENT, + `id_product` int(11) UNSIGNED NOT NULL, + `price` decimal(20,6) NOT NULL DEFAULT '0.000000', + `id_tax_rules_group` int(11) unsigned NOT NULL, + `id_element` int(11) unsigned NOT NULL, + `element_type` tinyint(11) unsigned NOT NULL, + PRIMARY KEY (`id_room_type_service_product_price`), + KEY `id_product` (`id_product`) + ) ENGINE="._MYSQL_ENGINE_." DEFAULT CHARSET=utf8 AUTO_INCREMENT=1;", + + "CREATE TABLE `"._DB_PREFIX_."htl_hotel_service_product_cart_detail` ( + `id_hotel_service_product_cart_detail` int(11) UNSIGNED NOT NULL AUTO_INCREMENT, + `id_cart` int(11) unsigned NOT NULL, + `id_product` int(11) UNSIGNED NOT NULL, + `id_hotel` int(11) UNSIGNED NOT NULL, + `quantity` int(11) UNSIGNED NOT NULL, + PRIMARY KEY (`id_hotel_service_product_cart_detail`), + KEY `id_product` (`id_product`) + ) ENGINE="._MYSQL_ENGINE_." DEFAULT CHARSET=utf8 AUTO_INCREMENT=1;", + + "CREATE TABLE `"._DB_PREFIX_."htl_room_type_service_product_cart_detail` ( + `id_room_type_service_product_cart_detail` int(11) UNSIGNED NOT NULL AUTO_INCREMENT, + `id_product` int(11) UNSIGNED NOT NULL, + `quantity` int(11) UNSIGNED NOT NULL, + `id_cart` int(11) unsigned NOT NULL, + `htl_cart_booking_id` int(11) unsigned NOT NULL, + PRIMARY KEY (`id_room_type_service_product_cart_detail`), + KEY `id_product` (`id_product`) + ) ENGINE="._MYSQL_ENGINE_." DEFAULT CHARSET=utf8 AUTO_INCREMENT=1;", + + "CREATE TABLE IF NOT EXISTS `"._DB_PREFIX_."htl_room_type_service_product_order_detail` ( + `id_room_type_service_product_order_detail` int(11) NOT NULL AUTO_INCREMENT, + `id_product` int(11) NOT NULL, + `id_order` int(11) NOT NULL, + `id_order_detail` int(11) NOT NULL, + `id_cart` int(11) NOT NULL, + `id_htl_booking_detail` int(11) NOT NULL, + `unit_price_tax_excl` decimal(20,6) NOT NULL, + `unit_price_tax_incl` decimal(20,6) NOT NULL, + `total_price_tax_excl` decimal(20,6) NOT NULL, + `total_price_tax_incl` decimal(20,6) NOT NULL, + `name` varchar(255) DEFAULT NULL, + `quantity` INT(11) UNSIGNED NOT NULL, + `auto_added` tinyint(1) unsigned NOT NULL, + `date_add` datetime NOT NULL, + `date_upd` datetime NOT NULL, + PRIMARY KEY (`id_room_type_service_product_order_detail`) + ) ENGINE="._MYSQL_ENGINE_." DEFAULT CHARSET=utf8 AUTO_INCREMENT=1;", + + "CREATE TABLE IF NOT EXISTS `"._DB_PREFIX_."htl_room_type_restriction_date_range` ( + `id_rt_restriction` int(11) NOT NULL AUTO_INCREMENT, + `id_product` int(11) NOT NULL, + `min_los` smallint(6) unsigned NOT NULL DEFAULT '1', + `max_los` smallint(6) unsigned NOT NULL DEFAULT '0', + `date_from` date NOT NULL, + `date_to` date NOT NULL, + `date_add` datetime NOT NULL, + `date_upd` datetime NOT NULL, + PRIMARY KEY (`id_rt_restriction`) + ) ENGINE="._MYSQL_ENGINE_." DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;", + + "CREATE TABLE IF NOT EXISTS `"._DB_PREFIX_."htl_settings_link` ( + `id_settings_link` int(11) NOT NULL AUTO_INCREMENT, + `icon` varchar(32) character set utf8 NOT NULL, + `link` text NOT NULL, + `new_window` tinyint(1) NOT NULL DEFAULT '0', + `position` int(11) unsigned NOT NULL DEFAULT '0', + `unremovable` tinyint(1) NOT NULL DEFAULT '0', + `active` tinyint(1) NOT NULL, + `date_add` datetime NOT NULL, + `date_upd` datetime NOT NULL, + PRIMARY KEY (`id_settings_link`) + ) ENGINE="._MYSQL_ENGINE_." DEFAULT CHARSET=utf8 AUTO_INCREMENT=1;", + + "CREATE TABLE IF NOT EXISTS `"._DB_PREFIX_."htl_settings_link_lang` ( + `id_settings_link` int(10) unsigned NOT NULL, + `id_lang` int(10) unsigned NOT NULL, + `name` varchar(255) character set utf8 NOT NULL, + `hint` varchar(255) character set utf8 NOT NULL, + PRIMARY KEY (`id_settings_link`, `id_lang`) + ) ENGINE="._MYSQL_ENGINE_." DEFAULT CHARSET=utf8;", + ); + } +} diff --git a/modules/statsforecast/upgrade/index.php b/modules/statsforecast/upgrade/index.php new file mode 100644 index 000000000..a2a4c7caf --- /dev/null +++ b/modules/statsforecast/upgrade/index.php @@ -0,0 +1,29 @@ + +* @copyright 2010-2023 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); +header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); + +header('Cache-Control: no-store, no-cache, must-revalidate'); +header('Cache-Control: post-check=0, pre-check=0', false); +header('Pragma: no-cache'); + +header('Location: ../../../'); +exit; diff --git a/modules/statsforecast/upgrade/upgrade-1.4.3.php b/modules/statsforecast/upgrade/upgrade-1.4.3.php new file mode 100644 index 000000000..365c730d0 --- /dev/null +++ b/modules/statsforecast/upgrade/upgrade-1.4.3.php @@ -0,0 +1,44 @@ + +* @copyright 2010-2022 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +if (!defined('_PS_VERSION_')) + exit; + +function upgrade_module_1_4_3($module) +{ + $objUpgrade = new UpgradeStatsForecast143($module); + return $objUpgrade->initUpgrade(); +} + +class UpgradeStatsForecast143 +{ + public function __construct($module) + { + $this->module = $module; + } + + public function initUpgrade() + { + if (!$this->module->registerHook('actionAdminControllerSetMedia')) { + return false; + } + return true; + } +} diff --git a/modules/wkfooteraboutblock/upgrade/index.php b/modules/wkfooteraboutblock/upgrade/index.php new file mode 100644 index 000000000..a2a4c7caf --- /dev/null +++ b/modules/wkfooteraboutblock/upgrade/index.php @@ -0,0 +1,29 @@ + +* @copyright 2010-2023 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); +header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); + +header('Cache-Control: no-store, no-cache, must-revalidate'); +header('Cache-Control: post-check=0, pre-check=0', false); +header('Pragma: no-cache'); + +header('Location: ../../../'); +exit; diff --git a/modules/wkfooteraboutblock/upgrade/upgrade-1.0.4.php b/modules/wkfooteraboutblock/upgrade/upgrade-1.0.4.php new file mode 100644 index 000000000..271fec9cf --- /dev/null +++ b/modules/wkfooteraboutblock/upgrade/upgrade-1.0.4.php @@ -0,0 +1,41 @@ + +* @copyright 2010-2022 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +if (!defined('_PS_VERSION_')) + exit; + +function upgrade_module_1_0_4($module) +{ + $objUpgrade = new UpgradeWkFooterAboutBlock104($module); + return $objUpgrade->initUpgrade(); +} + +class UpgradeWkFooterAboutBlock104 +{ + public function __construct($module) + { + $this->module = $module; + } + + public function initUpgrade() + { + return $this->module->unregisterHook('displayFooterPaymentInfo'); + } +} diff --git a/modules/wkfooterpaymentblock/upgrade/index.php b/modules/wkfooterpaymentblock/upgrade/index.php new file mode 100644 index 000000000..a2a4c7caf --- /dev/null +++ b/modules/wkfooterpaymentblock/upgrade/index.php @@ -0,0 +1,29 @@ + +* @copyright 2010-2023 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); +header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); + +header('Cache-Control: no-store, no-cache, must-revalidate'); +header('Cache-Control: post-check=0, pre-check=0', false); +header('Pragma: no-cache'); + +header('Location: ../../../'); +exit; diff --git a/modules/wkfooterpaymentblock/upgrade/upgrade-1.1.5.php b/modules/wkfooterpaymentblock/upgrade/upgrade-1.1.5.php new file mode 100644 index 000000000..6e9218d08 --- /dev/null +++ b/modules/wkfooterpaymentblock/upgrade/upgrade-1.1.5.php @@ -0,0 +1,41 @@ + +* @copyright 2010-2022 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +if (!defined('_PS_VERSION_')) + exit; + +function upgrade_module_1_1_5($module) +{ + $objUpgrade = new UpgradeWkFooterPaymentBlock115($module); + return $objUpgrade->initUpgrade(); +} + +class UpgradeWkFooterPaymentBlock115 +{ + public function __construct($module) + { + $this->module = $module; + } + + public function initUpgrade() + { + return $this->module->unregisterHook('displayAddModuleSettingLink'); + } +} diff --git a/modules/wkhotelfeaturesblock/upgrade/upgrade-2.0.6.php b/modules/wkhotelfeaturesblock/upgrade/upgrade-2.0.6.php new file mode 100644 index 000000000..9edc1cd26 --- /dev/null +++ b/modules/wkhotelfeaturesblock/upgrade/upgrade-2.0.6.php @@ -0,0 +1,41 @@ + +* @copyright 2010-2022 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +if (!defined('_PS_VERSION_')) + exit; + +function upgrade_module_2_0_6($module) +{ + $objUpgrade = new UpgradeWkHotelFeaturesBlock206($module); + return $objUpgrade->initUpgrade(); +} + +class UpgradeWkHotelFeaturesBlock206 +{ + public function __construct($module) + { + $this->module = $module; + } + + public function initUpgrade() + { + return $this->module->unregisterHook('displayAddModuleSettingLink'); + } +} diff --git a/modules/wkhotelroom/upgrade/upgrade-1.1.8.php b/modules/wkhotelroom/upgrade/upgrade-1.1.8.php new file mode 100644 index 000000000..9308a1d4f --- /dev/null +++ b/modules/wkhotelroom/upgrade/upgrade-1.1.8.php @@ -0,0 +1,41 @@ + +* @copyright 2010-2022 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +if (!defined('_PS_VERSION_')) + exit; + +function upgrade_module_1_1_8($module) +{ + $objUpgrade = new UpgradeWkHotelRoom118($module); + return $objUpgrade->initUpgrade(); +} + +class UpgradeWkHotelRoom118 +{ + public function __construct($module) + { + $this->module = $module; + } + + public function initUpgrade() + { + return $this->module->unregisterHook('displayAddModuleSettingLink'); + } +} diff --git a/modules/wktestimonialblock/upgrade/upgrade-1.1.6.php b/modules/wktestimonialblock/upgrade/upgrade-1.1.6.php new file mode 100644 index 000000000..e886e2ec1 --- /dev/null +++ b/modules/wktestimonialblock/upgrade/upgrade-1.1.6.php @@ -0,0 +1,41 @@ + +* @copyright 2010-2022 Webkul IN +* @license https://store.webkul.com/license.html +*/ + +if (!defined('_PS_VERSION_')) + exit; + +function upgrade_module_1_1_6($module) +{ + $objUpgrade = new UpgradeWkTestimonialBlock116($module); + return $objUpgrade->initUpgrade(); +} + +class UpgradeWkTestimonialBlock116 +{ + public function __construct($module) + { + $this->module = $module; + } + + public function initUpgrade() + { + return $this->module->unregisterHook('displayAddModuleSettingLink'); + } +} From 04fed51b10c773c4ebbf226b3ca73614bd793aaf Mon Sep 17 00:00:00 2001 From: Shreesh Arora Date: Wed, 9 Oct 2024 19:22:54 +0530 Subject: [PATCH 2/2] update license --- install/upgrade/php/add_new_categores_160.php | 21 +++++++++-------- .../php/add_new_order_refund_states_160.php | 21 +++++++++-------- install/upgrade/php/add_new_tabs_160.php | 21 +++++++++-------- ...ate_entry_for_payment_detail_table_160.php | 21 +++++++++++++++++ .../move_hotel_address_to_address_table.php | 21 +++++++++-------- .../php/move_hotel_categoryes_to_location.php | 21 +++++++++-------- .../php/update_order_payment_detail_160.php | 21 +++++++++-------- modules/blockcurrencies/upgrade/index.php | 23 +++++++++++-------- .../blockcurrencies/upgrade/upgrade-1.1.0.php | 23 +++++++++++-------- modules/blocklanguages/upgrade/index.php | 23 +++++++++++-------- .../blocklanguages/upgrade/upgrade-1.6.0.php | 23 +++++++++++-------- .../upgrade/upgrade-1.1.2.php | 23 +++++++++++-------- modules/dashguestcycle/upgrade/index.php | 23 +++++++++++-------- .../dashguestcycle/upgrade/upgrade-1.0.1.php | 23 +++++++++++-------- modules/dashoccupancy/upgrade/index.php | 23 +++++++++++-------- .../dashoccupancy/upgrade/upgrade-1.0.1.php | 23 +++++++++++-------- .../upgrade/upgrade-1.5.0.php | 23 +++++++++++-------- modules/statsforecast/upgrade/index.php | 23 +++++++++++-------- .../statsforecast/upgrade/upgrade-1.4.3.php | 23 +++++++++++-------- modules/wkfooteraboutblock/upgrade/index.php | 23 +++++++++++-------- .../upgrade/upgrade-1.0.4.php | 23 +++++++++++-------- .../wkfooterpaymentblock/upgrade/index.php | 23 +++++++++++-------- .../upgrade/upgrade-1.1.5.php | 23 +++++++++++-------- .../upgrade/upgrade-2.0.6.php | 23 +++++++++++-------- modules/wkhotelroom/upgrade/upgrade-1.1.8.php | 23 +++++++++++-------- .../upgrade/upgrade-1.1.6.php | 23 +++++++++++-------- 26 files changed, 340 insertions(+), 244 deletions(-) diff --git a/install/upgrade/php/add_new_categores_160.php b/install/upgrade/php/add_new_categores_160.php index f144ac0f4..18b49ee1a 100644 --- a/install/upgrade/php/add_new_categores_160.php +++ b/install/upgrade/php/add_new_categores_160.php @@ -1,21 +1,24 @@ -* @copyright 2010-2023 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); diff --git a/modules/blockcurrencies/upgrade/upgrade-1.1.0.php b/modules/blockcurrencies/upgrade/upgrade-1.1.0.php index 9ea699209..2b696f7df 100644 --- a/modules/blockcurrencies/upgrade/upgrade-1.1.0.php +++ b/modules/blockcurrencies/upgrade/upgrade-1.1.0.php @@ -1,21 +1,24 @@ -* @copyright 2010-2022 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ if (!defined('_PS_VERSION_')) diff --git a/modules/blocklanguages/upgrade/index.php b/modules/blocklanguages/upgrade/index.php index a2a4c7caf..409280877 100644 --- a/modules/blocklanguages/upgrade/index.php +++ b/modules/blocklanguages/upgrade/index.php @@ -1,21 +1,24 @@ -* @copyright 2010-2023 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); diff --git a/modules/blocklanguages/upgrade/upgrade-1.6.0.php b/modules/blocklanguages/upgrade/upgrade-1.6.0.php index b959a7415..314c45702 100644 --- a/modules/blocklanguages/upgrade/upgrade-1.6.0.php +++ b/modules/blocklanguages/upgrade/upgrade-1.6.0.php @@ -1,21 +1,24 @@ -* @copyright 2010-2022 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ if (!defined('_PS_VERSION_')) diff --git a/modules/blocknavigationmenu/upgrade/upgrade-1.1.2.php b/modules/blocknavigationmenu/upgrade/upgrade-1.1.2.php index b83ec8442..4c4b83db0 100644 --- a/modules/blocknavigationmenu/upgrade/upgrade-1.1.2.php +++ b/modules/blocknavigationmenu/upgrade/upgrade-1.1.2.php @@ -1,21 +1,24 @@ -* @copyright 2010-2022 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ if (!defined('_PS_VERSION_')) diff --git a/modules/dashguestcycle/upgrade/index.php b/modules/dashguestcycle/upgrade/index.php index a2a4c7caf..409280877 100644 --- a/modules/dashguestcycle/upgrade/index.php +++ b/modules/dashguestcycle/upgrade/index.php @@ -1,21 +1,24 @@ -* @copyright 2010-2023 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); diff --git a/modules/dashguestcycle/upgrade/upgrade-1.0.1.php b/modules/dashguestcycle/upgrade/upgrade-1.0.1.php index 4e6be25f3..0fdcc6428 100644 --- a/modules/dashguestcycle/upgrade/upgrade-1.0.1.php +++ b/modules/dashguestcycle/upgrade/upgrade-1.0.1.php @@ -1,21 +1,24 @@ -* @copyright 2010-2022 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ if (!defined('_PS_VERSION_')) diff --git a/modules/dashoccupancy/upgrade/index.php b/modules/dashoccupancy/upgrade/index.php index a2a4c7caf..409280877 100644 --- a/modules/dashoccupancy/upgrade/index.php +++ b/modules/dashoccupancy/upgrade/index.php @@ -1,21 +1,24 @@ -* @copyright 2010-2023 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); diff --git a/modules/dashoccupancy/upgrade/upgrade-1.0.1.php b/modules/dashoccupancy/upgrade/upgrade-1.0.1.php index ba27b1f30..72b2086ea 100644 --- a/modules/dashoccupancy/upgrade/upgrade-1.0.1.php +++ b/modules/dashoccupancy/upgrade/upgrade-1.0.1.php @@ -1,21 +1,24 @@ -* @copyright 2010-2022 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ if (!defined('_PS_VERSION_')) diff --git a/modules/hotelreservationsystem/upgrade/upgrade-1.5.0.php b/modules/hotelreservationsystem/upgrade/upgrade-1.5.0.php index ed4cbd45a..b7f0f14c4 100644 --- a/modules/hotelreservationsystem/upgrade/upgrade-1.5.0.php +++ b/modules/hotelreservationsystem/upgrade/upgrade-1.5.0.php @@ -1,21 +1,24 @@ -* @copyright 2010-2023 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ if (!defined('_PS_VERSION_')) diff --git a/modules/statsforecast/upgrade/index.php b/modules/statsforecast/upgrade/index.php index a2a4c7caf..409280877 100644 --- a/modules/statsforecast/upgrade/index.php +++ b/modules/statsforecast/upgrade/index.php @@ -1,21 +1,24 @@ -* @copyright 2010-2023 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); diff --git a/modules/statsforecast/upgrade/upgrade-1.4.3.php b/modules/statsforecast/upgrade/upgrade-1.4.3.php index 365c730d0..278917a4d 100644 --- a/modules/statsforecast/upgrade/upgrade-1.4.3.php +++ b/modules/statsforecast/upgrade/upgrade-1.4.3.php @@ -1,21 +1,24 @@ -* @copyright 2010-2022 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ if (!defined('_PS_VERSION_')) diff --git a/modules/wkfooteraboutblock/upgrade/index.php b/modules/wkfooteraboutblock/upgrade/index.php index a2a4c7caf..409280877 100644 --- a/modules/wkfooteraboutblock/upgrade/index.php +++ b/modules/wkfooteraboutblock/upgrade/index.php @@ -1,21 +1,24 @@ -* @copyright 2010-2023 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); diff --git a/modules/wkfooteraboutblock/upgrade/upgrade-1.0.4.php b/modules/wkfooteraboutblock/upgrade/upgrade-1.0.4.php index 271fec9cf..3e915b3c5 100644 --- a/modules/wkfooteraboutblock/upgrade/upgrade-1.0.4.php +++ b/modules/wkfooteraboutblock/upgrade/upgrade-1.0.4.php @@ -1,21 +1,24 @@ -* @copyright 2010-2022 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ if (!defined('_PS_VERSION_')) diff --git a/modules/wkfooterpaymentblock/upgrade/index.php b/modules/wkfooterpaymentblock/upgrade/index.php index a2a4c7caf..409280877 100644 --- a/modules/wkfooterpaymentblock/upgrade/index.php +++ b/modules/wkfooterpaymentblock/upgrade/index.php @@ -1,21 +1,24 @@ -* @copyright 2010-2023 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); diff --git a/modules/wkfooterpaymentblock/upgrade/upgrade-1.1.5.php b/modules/wkfooterpaymentblock/upgrade/upgrade-1.1.5.php index 6e9218d08..c77f6c2ca 100644 --- a/modules/wkfooterpaymentblock/upgrade/upgrade-1.1.5.php +++ b/modules/wkfooterpaymentblock/upgrade/upgrade-1.1.5.php @@ -1,21 +1,24 @@ -* @copyright 2010-2022 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ if (!defined('_PS_VERSION_')) diff --git a/modules/wkhotelfeaturesblock/upgrade/upgrade-2.0.6.php b/modules/wkhotelfeaturesblock/upgrade/upgrade-2.0.6.php index 9edc1cd26..3c9e31520 100644 --- a/modules/wkhotelfeaturesblock/upgrade/upgrade-2.0.6.php +++ b/modules/wkhotelfeaturesblock/upgrade/upgrade-2.0.6.php @@ -1,21 +1,24 @@ -* @copyright 2010-2022 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ if (!defined('_PS_VERSION_')) diff --git a/modules/wkhotelroom/upgrade/upgrade-1.1.8.php b/modules/wkhotelroom/upgrade/upgrade-1.1.8.php index 9308a1d4f..588e5884d 100644 --- a/modules/wkhotelroom/upgrade/upgrade-1.1.8.php +++ b/modules/wkhotelroom/upgrade/upgrade-1.1.8.php @@ -1,21 +1,24 @@ -* @copyright 2010-2022 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ if (!defined('_PS_VERSION_')) diff --git a/modules/wktestimonialblock/upgrade/upgrade-1.1.6.php b/modules/wktestimonialblock/upgrade/upgrade-1.1.6.php index e886e2ec1..53e422db6 100644 --- a/modules/wktestimonialblock/upgrade/upgrade-1.1.6.php +++ b/modules/wktestimonialblock/upgrade/upgrade-1.1.6.php @@ -1,21 +1,24 @@ -* @copyright 2010-2022 Webkul IN -* @license https://store.webkul.com/license.html +* @author Webkul IN +* @copyright Since 2010 Webkul +* @license https://opensource.org/license/osl-3-0-php Open Software License version 3.0 */ if (!defined('_PS_VERSION_'))