diff --git a/app/Classes/Modules/Orders/ControllersLogic/CreateBatchProcessingAutoCountImportLogic.php b/app/Classes/Modules/Orders/ControllersLogic/CreateBatchProcessingAutoCountImportLogic.php index 23f3915e..43538b6f 100644 --- a/app/Classes/Modules/Orders/ControllersLogic/CreateBatchProcessingAutoCountImportLogic.php +++ b/app/Classes/Modules/Orders/ControllersLogic/CreateBatchProcessingAutoCountImportLogic.php @@ -63,11 +63,15 @@ class CreateBatchProcessingAutoCountImportLogic extends AbstractControllerLogic $query->whereIn('type', [TransactionType::SHIPPING_INVOICE, TransactionType::STORAGE_INVOICE]) ->where('status', $approvalStatus); - $transactions = $query->whereHas('transactions', function($transaction) use ($startDate, $endDate) { - $transaction->where('type', TransactionType::PAYMENT) - ->whereBetween('updated_at', [$startDate, $endDate]) - ->whereIn('status', [ApprovalStatus::APPROVED, ApprovalStatus::COMPLETED]); - })->get(); + // $transactions = $query->whereHas('transactions', function($transaction) use ($startDate, $endDate) { + // $transaction->where('type', TransactionType::PAYMENT) + // ->whereBetween('updated_at', [$startDate, $endDate]) + // ->whereIn('status', [ApprovalStatus::APPROVED, ApprovalStatus::COMPLETED]); + // })->get(); + Log::info('CreateBatchProcessingAutoCountImportLogic startDate: ' . json_encode($startDate)); + Log::info('CreateBatchProcessingAutoCountImportLogic endDate: ' . json_encode($endDate)); + + $transactions = $query->whereBetween('created_at', [$startDate, $endDate])->get(); $count = 0; foreach ($transactions as $transaction) {