File tree 1 file changed +7
-6
lines changed
modules/qlohotelreview/classes
1 file changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -29,6 +29,8 @@ public static function getIsOrderCheckedOut($idOrder)
29
29
return (bool ) !Db::getInstance ()->getValue (
30
30
'SELECT COUNT(*) FROM ` ' ._DB_PREFIX_ .'htl_booking_detail` hbd
31
31
WHERE hbd.`id_status` != ' .(int ) HotelBookingDetail::STATUS_CHECKED_OUT .'
32
+ AND hbd.`is_refunded` != 1
33
+ AND hbd.`is_cancelled` != 1
32
34
AND hbd.`id_order` = ' .(int ) $ idOrder
33
35
);
34
36
}
@@ -57,6 +59,11 @@ public static function getIsReviewable($idOrder)
57
59
return false ;
58
60
}
59
61
62
+ $ objOrder = new Order ($ idOrder );
63
+ if ($ objOrder ->hasCompletelyRefunded ()) {
64
+ return false ;
65
+ }
66
+
60
67
if (self ::getIsOrderCheckedOut ($ idOrder )) {
61
68
return true ;
62
69
}
@@ -120,12 +127,6 @@ public static function getHotelByOrder($idOrder)
120
127
);
121
128
}
122
129
123
- public static function getPathForCreation ($ idHotelReview )
124
- {
125
- $ folders = str_split ((string )$ id_image );
126
- return implode ('/ ' , $ folders ).'/ ' ;
127
- }
128
-
129
130
public static function createDirectory ($ dir )
130
131
{
131
132
if (!file_exists ($ dir )) {
You can’t perform that action at this time.
0 commit comments