diff --git a/manager/bakery/bakery_stock_view.php b/manager/bakery/bakery_stock_view.php new file mode 100644 index 000000000..85760d9f4 --- /dev/null +++ b/manager/bakery/bakery_stock_view.php @@ -0,0 +1,269 @@ +modify('-7 days')->format('Y-m-d'); +$endDate = $_REQUEST["endDate"] ?? (clone $today)->modify('-1 day')->format('Y-m-d'); + +// 최종 수정시간 +$edit_datetime = date('Y-m-d H:i:s'); // 최종 수정 시간 업데이트 + +// 베이커리 계정인지 확인하고, 오늘 이후 날짜인 경우 생산-매출액란을 공란으로 출력하기 위한 변수 +$is_bakery = ( $_SESSION['user_id'] == "bakery" ) ? true : false; +$is_bakery_input = ( strtotime($searchDate) >= strtotime(date("Y-m-d")) ) ? true : false; + +// 합계 구하기 +$totalBakeryInvenData = getBakeryInvenSumPeriod($startDate, $endDate, $searchWord); +// barcode별 그룹화된 상세 데이터를 구하기 +$bakeryInvenData = getBakeryInvenDataPeriod($startDate, $endDate, $searchWord); + +?> + + + +
조회일자 : =$startDate?> ~ =$endDate?>
+| 품목 | +생산 | +업장사용 | +재활용 | +폐기 | +판매 | +매출액 | +
|---|---|---|---|---|---|---|
| =number_format(cntUsedBakeryItems())?> | +=number_format($totalBakeryInvenData['t_production'])?> | +=number_format($totalBakeryInvenData['t_inhouse_use'])?> | +=number_format($totalBakeryInvenData['t_recycling'])?> | +=number_format($totalBakeryInvenData['t_disposal'])?> | +=number_format($totalBakeryInvenData['t_sales'])?> | +=number_format($totalBakeryInvenData['t_payment_amount'])?> | +
| No. | +품목 | +생산 | +업장사용 | +재활용 | +폐기 | +판매 | +매출액 | +
|---|---|---|---|---|---|---|---|
| =$i?> | +=htmlspecialchars($row['product_name'])?> | +=number_format($row['production'])?> + + | +=number_format($row['inhouse_use'])?> + + | +=number_format($row['recycling'])?> + + | +=number_format($row['disposal'])?> + + | +=number_format($row['sales'])?> | +=number_format($row['payment_amount'])?> | +
| 합계 + | =number_format($totalBakeryInvenData['t_production'])?> | +=number_format($totalBakeryInvenData['t_inhouse_use'])?> | +=number_format($totalBakeryInvenData['t_recycling'])?> | +=number_format($totalBakeryInvenData['t_disposal'])?> | +=number_format($totalBakeryInvenData['t_sales'])?> | +=number_format($totalBakeryInvenData['t_payment_amount'])?> | +자료가 존재하지 않습니다 | "; + echo ""; + } // endif + + ?> +