From df137a1f4bb799ad96e35d16e37c2c9fbb9e37d5 Mon Sep 17 00:00:00 2001
From: wtt <1985833171@qq.com>
Date: 星期五, 23 五月 2025 09:34:04 +0800
Subject: [PATCH] 三升排产欠料优化

---
 WebTM/views/生产管理/三升排产/JIT_DayPlanPlatForm.html                 |    2 +-
 WebTM/views/生产管理/日计划报表/ReportWorkDemandPlanBillList.html       |    2 +-
 WebTM/views/生产管理/欠料运算/JIT_MaterialLevelShorAnalysisReport.html |   40 +++++++---------------------------------
 3 files changed, 9 insertions(+), 35 deletions(-)

diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\344\270\211\345\215\207\346\216\222\344\272\247/JIT_DayPlanPlatForm.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\344\270\211\345\215\207\346\216\222\344\272\247/JIT_DayPlanPlatForm.html"
index f48231c..170f652 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\344\270\211\345\215\207\346\216\222\344\272\247/JIT_DayPlanPlatForm.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\344\270\211\345\215\207\346\216\222\344\272\247/JIT_DayPlanPlatForm.html"
@@ -2837,7 +2837,7 @@
             });
 
             //鏍规嵁杞﹂棿鍒犻櫎娌℃湁閿佸畾鐨勬暟鎹�
-            var sql = "delete from Sc_WorkBillSortBillSub where HMasterDate>=convert(varchar(10) ,DATEADD(DAY," + HPlanDay + ",GETDATE()),20) and HInterID in(select  HInterID from Sc_WorkBillSortBillMain where HWorkShopID=" + HWorkShopID + " and HLockOrder != 1 )";
+            var sql = "delete from Sc_WorkBillSortBillSub where HMasterDate>=convert(varchar(10) ,DATEADD(DAY," + HPlanDay + ",GETDATE()),20) and HInterID in(select  HInterID from Sc_WorkBillSortBillMain where HWorkShopID=" + HWorkShopID + " and HLockOrder != 1 ) or HMasterDate < CAST(GETDATE() AS DATE)";
             $.ajax({
                 url: GetWEBURL() + '/Gy_SOPBillList/UpDelSQL',
                 type: "GET",
diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\227\245\350\256\241\345\210\222\346\212\245\350\241\250/ReportWorkDemandPlanBillList.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\227\245\350\256\241\345\210\222\346\212\245\350\241\250/ReportWorkDemandPlanBillList.html"
index 753bb1f..74a891a 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\227\245\350\256\241\345\210\222\346\212\245\350\241\250/ReportWorkDemandPlanBillList.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\227\245\350\256\241\345\210\222\346\212\245\350\241\250/ReportWorkDemandPlanBillList.html"
@@ -297,7 +297,7 @@
 
             var k = 0;//鏀堕泦寰幆娆℃暟
             for (var j = 0; j <= (Days - k); j++) {
-                columns.push({ field: Format(yyyy + '/' + MM + '/' + (HBEGINDATE + j), 'yyyy-MM-dd'), title: Format(yyyy + '/' + MM + '/' + (HBEGINDATE + j), 'MM.dd'), width: 70, totalRow: true})
+                columns.push({ field: Format(yyyy + '/' + MM + '/' + (HBEGINDATE + j), 'yyyy-MM-dd'), title: Format(yyyy + '/' + MM + '/' + (HBEGINDATE + j), 'MM-dd'), width: 70, totalRow: true})
                 //璺ㄥ勾鐨勮瘽 浼氫粠涓�鏈堜竴鍙峰紑濮�
                 if (MM == 12 && (HBEGINDATE + j) == 31) {
                     yyyy += 1;
diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\254\240\346\226\231\350\277\220\347\256\227/JIT_MaterialLevelShorAnalysisReport.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\254\240\346\226\231\350\277\220\347\256\227/JIT_MaterialLevelShorAnalysisReport.html"
index 31d1012..d352981 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\254\240\346\226\231\350\277\220\347\256\227/JIT_MaterialLevelShorAnalysisReport.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\254\240\346\226\231\350\277\220\347\256\227/JIT_MaterialLevelShorAnalysisReport.html"
@@ -234,35 +234,16 @@
         form.on('select(HInitTimeCycle)', function (data) {
             var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
             //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
-            if (HInitTimeCycle == 30) {
+            if (HInitTimeCycle !=0) {
                 //$('#HBeginDate').prop('disabled', true);
                 //$('#HEndDate').prop('disabled', true);
 
                 $("#HBEGINDATE").val(Format(new Date().setDate(new Date().getDate()), "yyyy-MM-dd"));//娆犳枡鏃ユ湡
-                $("#HENDDATE").val(Format(new Date().setDate(new Date().getDate() + 30), "yyyy-MM-dd"));//鑷�
+                $("#HENDDATE").val(Format(new Date().setDate(new Date().getDate() + HInitTimeCycle), "yyyy-MM-dd"));//鑷�
 
                 //鎵ц鏌ヨ鏂规硶
                 get_FastQuery();
-            } else if (HInitTimeCycle==45) {
-                //$('#HBeginDate').prop('disabled', true);
-                //$('#HEndDate').prop('disabled', true);
-
-                $("#HBEGINDATE").val(Format(new Date().setDate(new Date().getDate()-15), "yyyy-MM-dd"));//娆犳枡鏃ユ湡
-                $("#HENDDATE").val(Format(new Date().setDate(new Date().getDate() + 30), "yyyy-MM-dd"));//鑷�
-
-                //鎵ц鏌ヨ鏂规硶
-                get_FastQuery();
-            }
-            else if (HInitTimeCycle == 60) {
-                //$('#HBeginDate').prop('disabled', true);
-                //$('#HEndDate').prop('disabled', true);
-
-                $("#HBEGINDATE").val(Format(new Date().setDate(new Date().getDate() - 30), "yyyy-MM-dd"));//娆犳枡鏃ユ湡
-                $("#HENDDATE").val(Format(new Date().setDate(new Date().getDate() + 30), "yyyy-MM-dd"));//鑷�
-
-                //鎵ц鏌ヨ鏂规硶
-                get_FastQuery();
-            }
+            } 
             else {
                 $('#HBeginDate').prop('disabled', false);
                 $('#HEndDate').prop('disabled', false);
@@ -310,17 +291,10 @@
             setSelect_HInitTimeCycle();
             //鑻ユ棩鏈熼棿闅斾笉涓� 浠绘剰闂撮殧锛屽垯绂佺敤寮�濮嬫棩鏈熶笌缁撴潫鏃ユ湡鐨勯�夋嫨
             var HInitTimeCycle = $("#HInitTimeCycle").val() * 1;
-            if (HInitTimeCycle == 30) {
+            if (HInitTimeCycle !=0) {
                 $("#HBEGINDATE").val(Format(new Date().setDate(new Date().getDate()), "yyyy-MM-dd"));//娆犳枡鏃ユ湡
-                $("#HENDDATE").val(Format(new Date().setDate(new Date().getDate() + 30), "yyyy-MM-dd"));//鑷�
-            } else if (HInitTimeCycle == 45) {
-                $("#HBEGINDATE").val(Format(new Date().setDate(new Date().getDate() - 15), "yyyy-MM-dd"));//娆犳枡鏃ユ湡
-                $("#HENDDATE").val(Format(new Date().setDate(new Date().getDate() + 30), "yyyy-MM-dd"));//鑷�
-            }
-            else if (HInitTimeCycle == 60) {
-                $("#HBEGINDATE").val(Format(new Date().setDate(new Date().getDate() - 30), "yyyy-MM-dd"));//娆犳枡鏃ユ湡
-                $("#HENDDATE").val(Format(new Date().setDate(new Date().getDate() + 30), "yyyy-MM-dd"));//鑷�
-            }
+                $("#HENDDATE").val(Format(new Date().setDate(new Date().getDate() + HInitTimeCycle), "yyyy-MM-dd"));//鑷�
+            } 
             //鐢熶骇缁勭粐鍔犺浇
             Organ();
             //杞﹂棿
@@ -710,7 +684,7 @@
             $("#HInitTimeCycle").append(HInitTimeCycle_ArrayList);
             form.render('select');
 
-            $("#HInitTimeCycle").val("30");
+            $("#HInitTimeCycle").val("60");
         }
             //#endregion
 

--
Gitblit v1.9.1