Skip to content

Commit 15a2a24

Browse files
authored
Merge pull request #160 from shreesh-webkul/gli-517
fix new room issue for employee
2 parents 6b7ef21 + e22c3c1 commit 15a2a24

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Diff for: controllers/admin/AdminProductsController.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -80,9 +80,9 @@ public function __construct()
8080

8181
// START send access query information to the admin controller
8282
$this->access_select = ' SELECT a.`id_product` FROM '._DB_PREFIX_.'product a';
83-
$this->access_join = ' INNER JOIN '._DB_PREFIX_.'htl_room_type hrt ON (hrt.id_product = a.id_product)';
83+
$this->access_join = ' LEFT JOIN '._DB_PREFIX_.'htl_room_type hrt ON (hrt.id_product = a.id_product)';
8484
if ($acsHtls = HotelBranchInformation::getProfileAccessedHotels($this->context->employee->id_profile, 1, 1)) {
85-
$this->access_where = ' WHERE hrt.id_hotel IN ('.implode(',', $acsHtls).')';
85+
$this->access_where = ' WHERE (hrt.id_hotel IN ('.implode(',', $acsHtls).') OR hrt.id_hotel IS NULL)';
8686
}
8787

8888
parent::__construct();

0 commit comments

Comments
 (0)