diff --git a/public_html/doc/export_process.php b/public_html/doc/export_process.php
index b93ed80..62ad285 100644
--- a/public_html/doc/export_process.php
+++ b/public_html/doc/export_process.php
@@ -788,10 +788,14 @@ if ($actionStr == "CUSTOMER") {
$baseDate = strtotime($c_schedulebasic);
$targetDate = strtotime($orderdate);
$diffDays = floor(($targetDate - $baseDate) / 86400);
- $diffWeeks = floor($diffDays / 7);
- if (($diffWeeks % $weekNum) == 0) {
- $isScheduleMatch = true;
- }
+ // 과거 제외
+ if ($diffDays >= 0) {
+ $diffWeeks = floor($diffDays / 7);
+ // n주 간격 체크
+ if (($diffWeeks % $weekNum) == 0) {
+ $isScheduleMatch = true;
+ }
+ }
}
if (!$isScheduleMatch) {
diff --git a/public_html/doc/forecast_list.php b/public_html/doc/forecast_list.php
index bcb021b..9051a4b 100644
--- a/public_html/doc/forecast_list.php
+++ b/public_html/doc/forecast_list.php
@@ -268,10 +268,13 @@ if ($c_type_p == 'P') {
$targetDate = strtotime($orderdate);
// 날짜 차이
$diffDays = floor(($targetDate - $baseDate) / 86400);
- $diffWeeks = floor($diffDays / 7);
- // n주 간격 체크
- if (($diffWeeks % $weekNum) == 0) {
- $isScheduleMatch = true;
+ // 과거 제외
+ if ($diffDays >= 0) {
+ $diffWeeks = floor($diffDays / 7);
+ // n주 간격 체크
+ if (($diffWeeks % $weekNum) == 0) {
+ $isScheduleMatch = true;
+ }
}
}
}
@@ -743,10 +746,13 @@ if ($c_type_p == 'P') {
$targetDate = strtotime($orderdate);
// 날짜 차이
$diffDays = floor(($targetDate - $baseDate) / 86400);
- $diffWeeks = floor($diffDays / 7);
- // n주 간격 체크
- if (($diffWeeks % $weekNum) == 0) {
- $isScheduleMatch = true;
+ // 과거 제외
+ if ($diffDays >= 0) {
+ $diffWeeks = floor($diffDays / 7);
+ // n주 간격 체크
+ if (($diffWeeks % $weekNum) == 0) {
+ $isScheduleMatch = true;
+ }
}
}
}