Compare commits
5 Commits
20250806-1
...
20250806-2
| Author | SHA1 | Date | |
|---|---|---|---|
| fdb5d99214 | |||
| b202835205 | |||
| 44a500df9f | |||
| 1a962ecb39 | |||
| 24a911d63a |
@@ -91,6 +91,6 @@ class UserSite extends Model
|
|||||||
*/
|
*/
|
||||||
public function getUserDefaultInfoByUserId(int $userId)
|
public function getUserDefaultInfoByUserId(int $userId)
|
||||||
{
|
{
|
||||||
return $this->where('user_id', $userId)->where('is_default',SiteCode::USER_NO_DEFAULT)->first();
|
return $this->where('user_id', $userId)->where('is_default',SiteCode::USER_DEFAULT)->first();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -47,7 +47,7 @@ class FinancesService extends BaseService
|
|||||||
->when($searchKitchenId, function ($query) use ($searchKitchenId) {
|
->when($searchKitchenId, function ($query) use ($searchKitchenId) {
|
||||||
$query->where('kitchen_id', $searchKitchenId);
|
$query->where('kitchen_id', $searchKitchenId);
|
||||||
})
|
})
|
||||||
->groupBy('cycle_id')
|
->groupBy('cycle_id','date')
|
||||||
->orderByDesc('cycle_id')
|
->orderByDesc('cycle_id')
|
||||||
->select(
|
->select(
|
||||||
'date',
|
'date',
|
||||||
|
|||||||
@@ -156,11 +156,11 @@ class OrderInfoService extends BaseService
|
|||||||
|
|
||||||
for ($i = 1; $i <= (count($newOrderSkuList) ?? 0); $i++) {
|
for ($i = 1; $i <= (count($newOrderSkuList) ?? 0); $i++) {
|
||||||
|
|
||||||
$pickupCodeOneCopies = $pickupCodeArrList[$order['id']][$i]['pickup_code'] ?? null;
|
$pickupCodeOneCopies = $pickupCodeList[$i] ?? null;
|
||||||
$boxNum = 0;
|
$boxNum = 0;
|
||||||
if (!empty($pickupCodeOneCopies)) {
|
if (!empty($pickupCodeOneCopies)) {
|
||||||
$pickupCodeOneCopiesArr = explode('-', $pickupCodeOneCopies);
|
$pickupCodeOneCopiesArr = explode('-', $pickupCodeOneCopies);
|
||||||
$boxNum = ceil(end($pickupCodeOneCopiesArr) ?? '0' / (int)$this->configCache->getConfigValueByKey(ConfigCode::MAXIMUM_VALUE_IN_FULL_BOX));
|
$boxNum = ceil((int)(end($pickupCodeOneCopiesArr) ?? 0) / (int)$this->configCache->getConfigValueByKey(ConfigCode::MAXIMUM_VALUE_IN_FULL_BOX));
|
||||||
}
|
}
|
||||||
|
|
||||||
$oneCopiesInfo = [
|
$oneCopiesInfo = [
|
||||||
|
|||||||
@@ -184,7 +184,7 @@ class OrderListService extends BaseService
|
|||||||
$boxNum = 0;
|
$boxNum = 0;
|
||||||
if (!empty($pickupCodeOneCopies)) {
|
if (!empty($pickupCodeOneCopies)) {
|
||||||
$pickupCodeOneCopiesArr = explode('-', $pickupCodeOneCopies);
|
$pickupCodeOneCopiesArr = explode('-', $pickupCodeOneCopies);
|
||||||
$boxNum = ceil(end($pickupCodeOneCopiesArr) ?? '0' / (int)$this->configCache->getConfigValueByKey(ConfigCode::MAXIMUM_VALUE_IN_FULL_BOX));
|
$boxNum = ceil((int)(end($pickupCodeOneCopiesArr) ?? 0) / (int)$this->configCache->getConfigValueByKey(ConfigCode::MAXIMUM_VALUE_IN_FULL_BOX));
|
||||||
}
|
}
|
||||||
$oneCopiesInfo = [
|
$oneCopiesInfo = [
|
||||||
'total_price' => '0.00',
|
'total_price' => '0.00',
|
||||||
|
|||||||
Reference in New Issue
Block a user