diff --git a/app/Http/Controllers/Admin/StatisticsController.php b/app/Http/Controllers/Admin/StatisticsController.php index ed3b59d..e1b61b3 100755 --- a/app/Http/Controllers/Admin/StatisticsController.php +++ b/app/Http/Controllers/Admin/StatisticsController.php @@ -385,7 +385,6 @@ class StatisticsController extends CommonController "orders.to_date", "orders.contact", "orders.mobile", - "orders.status", "customers.mobile", "patient.name" ) @@ -400,15 +399,6 @@ class StatisticsController extends CommonController "orders.contact", "orders.mobile as contact_mobile", DB::raw("'" . $before_datetime_text . "' as point_time"), - DB::raw(" - CASE orders.status - WHEN " . Orders::STATUS_UNCONFIRMED . " THEN '" . Orders::TEXT_UNCONFIRMED . "' - WHEN " . Orders::STATUS_UNASSIGNED . " THEN '" . Orders::TEXT_UNASSIGNED . "' - WHEN " . Orders::STATUS_ONGOING . " THEN '" . Orders::TEXT_ONGOING . "' - WHEN " . Orders::STATUS_FINISHED . " THEN '" . Orders::TEXT_FINISHED . "' - ELSE orders.status - END as status_name - "), "customers.mobile as customer_mobile", "patient.name as patient_name", DB::raw("COALESCE(SUM(balance.money), 0) as balance"), @@ -421,14 +411,13 @@ class StatisticsController extends CommonController $sheet->setCellValue('A1', '项目名称'); $sheet->setCellValue('B1', '时点'); $sheet->setCellValue('C1', '订单号'); - $sheet->setCellValue('D1', '订单状态'); - $sheet->setCellValue('E1', '客户手机号'); - $sheet->setCellValue('F1', '联系人'); - $sheet->setCellValue('G1', '联系电话'); - $sheet->setCellValue('H1', '被陪护人'); - $sheet->setCellValue('I1', '服务开始'); - $sheet->setCellValue('J1', '服务结束'); - $sheet->setCellValue('K1', '时点余额'); + $sheet->setCellValue('D1', '客户手机号'); + $sheet->setCellValue('E1', '联系人'); + $sheet->setCellValue('F1', '联系电话'); + $sheet->setCellValue('G1', '被陪护人'); + $sheet->setCellValue('H1', '服务开始'); + $sheet->setCellValue('I1', '服务结束'); + $sheet->setCellValue('J1', '时点余额'); $count = count($rows); for ($i = 2; $i <= $count + 1; $i++) { @@ -436,14 +425,13 @@ class StatisticsController extends CommonController $sheet->setCellValue('A' . $i, $row['project_name']); $sheet->setCellValue('B' . $i, $row['point_time']); $sheet->setCellValue('C' . $i, $row['serial']); - $sheet->setCellValue('D' . $i, $row['status_name']); - $sheet->setCellValue('E' . $i, $row['customer_mobile']); - $sheet->setCellValue('F' . $i, $row['contact']); - $sheet->setCellValue('G' . $i, $row['contact_mobile']); - $sheet->setCellValue('H' . $i, $row['patient_name']); - $sheet->setCellValue('I' . $i, $row['from_date']); - $sheet->setCellValue('J' . $i, $row['to_date']); - $sheet->setCellValue('K' . $i, $row['balance']); + $sheet->setCellValue('D' . $i, $row['customer_mobile']); + $sheet->setCellValue('E' . $i, $row['contact']); + $sheet->setCellValue('F' . $i, $row['contact_mobile']); + $sheet->setCellValue('G' . $i, $row['patient_name']); + $sheet->setCellValue('H' . $i, $row['from_date']); + $sheet->setCellValue('I' . $i, $row['to_date']); + $sheet->setCellValue('J' . $i, $row['balance']); } header('Content-Type: application/vnd.ms-excel'); header('Content-Disposition: attachment;filename="' . ($project ? $project->name : '项目') . '_订单时点余额_' . date('YmdHis') . '.xlsx"'); diff --git a/resources/views/admin/statistics/customer-balance.blade.php b/resources/views/admin/statistics/customer-balance.blade.php index 1f05f41..e9cf78a 100755 --- a/resources/views/admin/statistics/customer-balance.blade.php +++ b/resources/views/admin/statistics/customer-balance.blade.php @@ -62,7 +62,6 @@ 项目名称 时点 订单号 - 订单状态 客户手机号 联系人 联系电话 @@ -79,7 +78,6 @@ {{ $item->project_name }} {{ $item->point_time }} {{ $item->serial }} - {{ $item->status_name }} {{ $item->customer_mobile }} {{ $item->contact }} {{ $item->contact_mobile }}