Merge pull request #1650 from AradhanaSingh63/gli-2738

Fixed: Hotel-wise access permission for the credit slip in back-office
This commit is contained in:
Rohit Jain
2026-01-24 13:43:16 +05:30
committed by GitHub
2 changed files with 3 additions and 1 deletions

View File

@@ -277,7 +277,7 @@ class OrderSlipCore extends ObjectModel
FROM `'._DB_PREFIX_.'order_slip` os
LEFT JOIN `'._DB_PREFIX_.'orders` o ON (o.`id_order` = os.`id_order`)
WHERE os.`date_add` BETWEEN \''.pSQL($dateFrom).' 00:00:00\' AND \''.pSQL($dateTo).' 23:59:59\'
'.Shop::addSqlRestriction(Shop::SHARE_ORDER, 'o').'
'.Shop::addSqlRestriction(Shop::SHARE_ORDER, 'o'). ' ' .HotelBranchInformation::addHotelRestriction(false).'
ORDER BY os.`date_add` ASC');
$slips = array();

View File

@@ -38,6 +38,8 @@ class AdminSlipControllerCore extends AdminController
$this->_select = ' o.`id_shop`';
$this->_join .= ' LEFT JOIN '._DB_PREFIX_.'orders o ON (o.`id_order` = a.`id_order`)';
$this->_join .= ' INNER JOIN '._DB_PREFIX_.'htl_booking_detail hbd
ON (a.`id_order` = hbd.`id_order`) ' . HotelBranchInformation::addHotelRestriction(false, 'hbd');
$this->_group = ' GROUP BY a.`id_order_slip`';
$this->addRowAction('statusChange');