Browse Source

核对准确全部看板

忠帅 张 2 năm trước cách đây
mục cha
commit
0b91d145c7

+ 29 - 51
wwwroot/main/Procedure/Boardkanban/Boardkanban.ashx

@@ -131,17 +131,18 @@ public class  FormingKanban : IHttpHandler, IReadOnlySessionState
 				{
 				string sqlStr = @"
 								WITH  一烧出窑量 as (SELECT  COUNT(*) AS 一烧出窑量 FROM TP_PM_PRODUCTIONDATA 
-													WHERE PROCEDUREID IN(56,14) AND VALUEFLAG=1 AND TRUNC(CREATETIME)=TRUNC(SYSDATE)
+													WHERE PROCEDUREID IN(16) AND VALUEFLAG=1  AND TRUNC(CREATETIME)>={first}  AND TRUNC(CREATETIME)<={second} 
 													),
 													一烧产量 as (
 
 													SELECT  COUNT(*) 一烧产量 FROM TP_PM_PRODUCTIONDATA 
-													WHERE PROCEDUREID IN(15,16) AND VALUEFLAG=1 AND TRUNC(CREATETIME)=TRUNC(SYSDATE)
-													AND GOODSLEVELID=4
+													WHERE PROCEDUREID IN(16) AND VALUEFLAG=1  AND TRUNC(CREATETIME)>={first}  AND TRUNC(CREATETIME)<={second} 
+
+													AND GOODSLEVELID IN(4,5)
 													),
 													综合产量 as (
 													SELECT COUNT(*)综合数量 FROM TP_PM_PRODUCTIONDATA
-													WHERE PROCEDUREID IN(15,16,27,28) AND VALUEFLAG=1 AND TRUNC(CREATETIME)=TRUNC(SYSDATE)
+													WHERE PROCEDUREID IN(16,28) AND VALUEFLAG=1  AND TRUNC(CREATETIME)>={first}  AND TRUNC(CREATETIME)<={second} 
 													)
 													SELECT 
 													一烧出窑量.一烧出窑量,
@@ -149,7 +150,7 @@ public class  FormingKanban : IHttpHandler, IReadOnlySessionState
 													综合产量.综合数量
 													FROM 一烧出窑量
 													LEFT JOIN 一烧产量 on 1=1
-													LEFT JOIN 综合产量 on 1=1	";
+													LEFT JOIN 综合产量 on 1=1		".Replace("{first}",first).Replace("{second}",second);
 								//直接获取不分页数据
 								DataTable dt = conn.ExecuteDatatable(sqlStr);
 								string jsonStr = new JsonResult(dt).ToJson();
@@ -230,8 +231,8 @@ public class  FormingKanban : IHttpHandler, IReadOnlySessionState
 												缺陷.缺陷名称,
 												缺陷.缺陷数量,
 												其他缺陷.其他缺陷数量  AS 其他缺陷数量 ,
-												DECODE( NVL( 缺陷.缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 缺陷.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.0' ) || '%' ) 缺陷率,
-												DECODE( NVL( 其他缺陷.其他缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 其他缺陷.其他缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.0' ) || '%' ) 其他缺陷率
+												DECODE( NVL( 缺陷.缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 缺陷.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.00' ) || '%' ) 缺陷率,
+												DECODE( NVL( 其他缺陷.其他缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 其他缺陷.其他缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.00' ) || '%' ) 其他缺陷率
 											FROM
 												缺陷
 												LEFT JOIN 检验数 ON 1 = 1
@@ -254,7 +255,7 @@ public class  FormingKanban : IHttpHandler, IReadOnlySessionState
 												)
 												SELECT
 												一烧产量.出窑数,
-												DECODE( NVL( 一烧产量.出窑数, 0 ),0,'0%',TO_CHAR((NVL( 一烧产量.出窑数, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.0' ) || '%' ) as 一烧合格率
+												DECODE( NVL( 一烧产量.出窑数, 0 ),0,'0%',TO_CHAR((NVL( 一烧产量.出窑数, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.00' ) || '%' ) as 一烧合格率
 												FROM  
 												一烧产量
 												LEFT JOIN 检验数 on 1=1 ";
@@ -275,7 +276,7 @@ SELECT
 									产品分级
 								FROM(
 							SELECT DISTINCT
-										stf.STAFFCODE 责任工号,
+									 pd.GROUTINGUSERCODE 责任工号,
 										TMDP.BARCODE 条码,
 										pd.GOODSCODE 产品编码,
 										TMDP.DEFECTNAME 缺陷名称,
@@ -305,7 +306,7 @@ SELECT
 								
 											FROM(
 											SELECT
-										  stf.STAFFCODE 责任工号,
+										  pd.GROUTINGUSERCODE 责任工号,
 										  pd.BARCODE 条码,
 										  pd.GOODSCODE 产品编码,
 										  ' ' as 缺陷名称,
@@ -333,23 +334,7 @@ SELECT
 
 		if (context.Request["m"].ToString() == "rate")//折线图
 			{
-				string sqlStr = @"	with	缺陷 AS 
-												(
-												SELECT
-												SJ,
-												SUM(缺陷数量) AS 缺陷数量
-												FROM(
-												SELECT
-												TO_CHAR(dfc.CREATETIME,'MM-DD')AS SJ,
-												COUNT(dfc.BARCODE) 缺陷数量
-												FROM TP_PM_DEFECT dfc
-												LEFT JOIN TP_MST_DEFECT df ON df.DEFECTID = dfc.DEFECTID 
-												WHERE dfc.VALUEFLAG=1 AND TRUNC(dfc.CREATETIME)>= {first} AND TRUNC(dfc.CREATETIME)< {second}
-												GROUP BY dfc.CREATETIME
-												) GROUP BY SJ
-												ORDER BY SJ
-												),
-												一烧产量 AS 
+				string sqlStr = @"		with	一烧产量 AS 
 												(
 												SELECT
 												SJ,
@@ -359,23 +344,14 @@ SELECT
 												SELECT
 												TO_CHAR(CREATETIME,'MM-DD')AS SJ,
 												 COUNT( * ) 一烧产量 FROM TP_PM_PRODUCTIONDATA 
-												WHERE PROCEDUREID IN (15,16)  AND GOODSLEVELTYPEID IN (1,4,5)   
-												and VALUEFLAG=1 AND TRUNC(CREATETIME)>= {first}  AND TRUNC(CREATETIME)<{second}
+												WHERE PROCEDUREID IN (15,16)  AND GOODSLEVELTYPEID IN (4,5)   
+												and VALUEFLAG=1 AND TRUNC(CREATETIME)>=  {first}AND TRUNC(CREATETIME)< {second}
 												GROUP BY CREATETIME)
 												GROUP BY SJ ORDER BY SJ
 												),
-												检验数 AS (
-													SELECT 
-													SJ,
-													SUM(一烧出窑数) AS 一烧出窑数
-													FROM(
-													 SELECT
-													 TO_CHAR(CREATETIME,'MM-DD')AS SJ,
-													 COUNT( * ) 一烧出窑数 
-													 FROM TP_PM_PRODUCTIONDATA WHERE PROCEDUREID =16  and VALUEFLAG=1 	AND TRUNC(CREATETIME)>= (ADD_MONTHS(TRUNC(SYSDATE, 'MM'), -1) + 25) AND TRUNC(CREATETIME)<(ADD_MONTHS(TRUNC(SYSDATE, 'MM'), 0) + 25)+23/24 +59/(24*60)
-													GROUP BY CREATETIME)
-													GROUP BY SJ ORDER BY SJ
-												),
+												
+												
+												
 												一烧出窑量 AS 
 												(
 												SELECT
@@ -385,17 +361,19 @@ SELECT
 												SELECT
 													TO_CHAR(CREATETIME,'MM-DD')AS SJ,
 												 COUNT( * ) 一烧出窑量 FROM TP_PM_PRODUCTIONDATA
-												 WHERE PROCEDUREID IN (14,56)    and VALUEFLAG=1 
-												 AND TRUNC(CREATETIME)>= {first} AND TRUNC(CREATETIME)<{second}
+												 WHERE PROCEDUREID =16     and VALUEFLAG=1 
+												 AND TRUNC(CREATETIME)>=  {first} AND TRUNC(CREATETIME)< {second}
 												 GROUP BY CREATETIME)
 												 GROUP BY  SJ ORDER BY SJ
 												),
+												
+												
 												时间 AS (
 													SELECT
 													TO_CHAR(CREATETIME,'MM-DD')AS SJ
 												  FROM TP_PM_PRODUCTIONDATA
 												 WHERE 
-												  TRUNC(CREATETIME)>= {first} AND TRUNC(CREATETIME)<{second}
+												  TRUNC(CREATETIME)>=  {first} AND TRUNC(CREATETIME)< {second}
 													GROUP BY 	TO_CHAR(CREATETIME,'MM-DD')
 											)
 												
@@ -405,19 +383,19 @@ SELECT
 												NVL( 一烧产量.一烧产量, 0 ) 一烧产量,
 												NVL( 一烧出窑量.一烧出窑量, 0 ) 一烧出窑量,
 												CASE WHEN 一烧出窑量.一烧出窑量 is NULL THEN '0%' ELSE 
-												DECODE( NVL( 缺陷.缺陷数量, 0 ),0,'0%',
-												TO_CHAR( CASE WHEN (  ( NVL( 检验数.一烧出窑数, 1 )- NVL( 缺陷.缺陷数量, 0 )  ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100<=0
+												DECODE( NVL( 一烧产量.一烧产量, 0 ),0,'0%',
+												TO_CHAR( CASE WHEN (  ( NVL( 一烧产量.一烧产量, 1 )  ) / DECODE( NVL( 一烧出窑量.一烧出窑量, 1 ), 0, 1, NVL( 一烧出窑量.一烧出窑量, 1 ) ) ) * 100<=0
 												THEN 0 
 												ELSE 
-												(  ( NVL( 检验数.一烧出窑数, 1 )- NVL( 缺陷.缺陷数量, 0 )  ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100 end
-												,'fm99990.0' ) ) END  一烧合格率
+												(  ( NVL( 一烧产量.一烧产量, 1 )) / DECODE( NVL( 一烧出窑量.一烧出窑量, 1 ), 0, 1, NVL( 一烧出窑量.一烧出窑量, 1 ) ) ) * 100 end
+												,'fm99990.00' ) ) END  一烧合格率
 												FROM 时间
-												left JOIN 缺陷 ON 时间.SJ=缺陷.SJ
-												left JOIN 一烧产量 ON 缺陷.SJ=一烧产量.SJ
+												left JOIN 一烧产量 ON 时间.SJ=一烧产量.SJ
 												LEFT JOIN 一烧出窑量 ON 一烧出窑量.SJ=时间.SJ
-												LEFT JOIN 检验数 on 检验数.SJ=一烧出窑量.SJ
 												ORDER BY 	时间.SJ
 												
+												
+												
 												".Replace("{first}",first).Replace("{second}",second);
                 //直接获取不分页数据
                 DataTable dt = conn.ExecuteDatatable(sqlStr);

+ 120 - 30
wwwroot/main/Procedure/Boardkanban/Boardkanban.html

@@ -29,31 +29,35 @@
         <div class="box_body" style="display: flex; flex-direction: column;">
 
             <!--31天产量曲线图-->
-            <div style="width:1840px;height:30%;display:flex;flex-direction:row;">
-                <div style="width: 75%; height: 300px;">
-                    <div style="color:white;font-size:15px;font-weight:600; text-align:center">每日产量计划达成</div>
-                    <canvas id="canvasDayCL" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 330px; width: 80% "></canvas>
+            <div style="width:1840px;height:40%;display:flex;flex-direction:row;">
+                <div style="width: 75%; height: 200px;">
+                    <canvas id="canvasDayCL" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 300px; width: 100% "></canvas>
+                </div>
+            </div>
+            <div style="width:1840px;height:40%;display:flex;flex-direction:row; margin-top:-5%">
+                <div style="width: 75%; height: 100px;">
+                    <canvas id="canvasMonthCL" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 120px; width: 100%;"></canvas>
                 </div>
             </div>
 
             <div>
-                <table rules="none" align="right" style="width: 20%; height: 270px; margin-left:80%;margin-top:-291px ">
+                <table rules="none" align="right" style="width: 22%; height: 270px; margin-left: 80%; margin-top: -691px ">
                     <tr class="tr_title_warning">
                         <td style="width: 8%; height: 60px; font-size: 30px; text-align: left" colspan="2"><strong><span id="sj" style="color:white;">2023-4-30 00:00:00</span></strong></td>
                     </tr>
                     <tr class="tr_title_warning">
-                        <td style="width: 8%; height: 95px; font-size: 30px; text-align: left ">一烧产量:<span id="ysc"  style="color:white;">加载中...</span></td>
+                        <td style="width: 8%; height: 95px; font-size: 30px; text-align: left ">月度一烧产量:&nbsp;&nbsp;&nbsp;<span id="ysc" style="color:white;"> 加载中...</span></td>
                     </tr>
                     <tr class="tr_title_warning">
-                        <td style="width: 8%; height: 95px; font-size: 30px; text-align: left ">综合产量:<span id="zhc"  style="color:white;">加载中...</span></td>
+                        <td style="width: 8%; height: 95px; font-size: 30px; text-align: left ">月度综合产量:&nbsp;&nbsp;&nbsp;<span id="zhc" style="color:white;"> 加载中...</span></td>
                     </tr>
                     <tr class="tr_title_warning">
-                        <td style="width: 8%; height: 95px; font-size: 30px; text-align: left ">一烧出窑量:<span id="yscy"  style="color:white;">加载中...</span></td>
+                        <td style="width: 8%; height: 95px; font-size: 30px; text-align: left ">月度一烧出窑量:<span id="yscy" style="color:white;">加载中...</span></td>
                     </tr>
                 </table>
             </div>
             <!--表格-->
-            <div style="width: 100%; height: 530px; display: flex; flex-direction: row; margin-top: 4%">
+            <div style="width: 100%; height: 530px; display: flex; flex-direction: row; margin-top: -14%">
                 <div style="width: 100%; height: 530px; ">
                     <table cellspacing="0" cellpadding="0" border="0" style="width:50%;">
                         <tr class="tr_title_warning">
@@ -86,7 +90,7 @@
 
                     <table cellspacing="0" cellpadding="0" border="0" style="width: 50%;">
                         <tr class="tr_title_warning" style="height: 60px; font-size: 30px">
-                            <td colspan="3" style="width:50%" >缺陷率:<span id="dmqxl" style="color:white;">——</span></td>
+                            <td colspan="3" style="width:50%">一烧合格率:<span id="dmqxl" style="color:white;">——</span></td>
                             <td colspan="3" style="width:50%">一烧产量:<span id="cxqxl" style="color:white">——</span></td>
 
                         </tr>
@@ -123,7 +127,7 @@
                         <td colspan="4" style="color: white; font-size: 30px;">成检实时数据</td>
                     </tr>
                     <tr class="tr_title_warning">
-                        <td style="font-size: 27px; width: 25%; height: 30px; ">责任工号</td>
+                        <td style="font-size: 27px; width: 25%; height: 30px; ">注浆工号</td>
                         <td style="font-size: 27px; width: 25%; height: 30px; ">产品编码</td>
                         <td style="font-size: 27px; width: 25%; height: 30px; ">缺陷名称</td>
                         <td style="font-size: 27px; width: 25%; height: 30px; ">产品分级</td>
@@ -159,6 +163,7 @@
         //页面加载
         $(document).ready(function () {
             initData();
+            initData2();
             timeUp();
             StaffTable();
 			doGetData = setInterval(function () { loadServerTime(); }, 3000);
@@ -177,7 +182,7 @@
 			$.get('Boardkanban.ashx?m=Alltotal', function (data) {
 				var json = JSON.parse(data);
 				if (json["success"] == true) {
-					$('#dmqxl').text(json["rows"][0]["打磨缺陷率"]);
+					$('#dmqxl').text(json["rows"][0]["一烧合格率"]);
                     $('#cxqxl').text( json["rows"][0]["出窑数"]);
 				}
 			});
@@ -267,12 +272,17 @@
         function clearData() {
             //清除数据
             window.DayCL.data.labels = [];
-            //window.DayCL.data.datasets[0].data = [0, 0, 0, 0, 0, 0, 0];
             window.DayCL.data.datasets[0].data = [];
-            //window.DayCL.data.datasets[1].data = [0, 0, 0, 0, 0, 0, 0];
             window.DayCL.data.datasets[1].data = [];
             window.DayCL.update();
         }
+
+		function clearData2() {
+			//清除数据
+			window.MonthCL.data.labels = [];
+			window.MonthCL.data.datasets[0].data = [];
+			window.MonthCL.update();
+		}
 		function loadServerTime() {
 			$.get('Boardkanban.ashx?m=fwq', function (data) {
 				var json = JSON.parse(data);
@@ -305,13 +315,29 @@
                 if (json["success"] == true) {
                     for (var n = 0; n < json["rows"].length; n++) {
                         window.DayCL.data.labels.push(json["rows"][n]["SJ"]);
-                        window.DayCL.data.datasets[0].data[n] = (json["rows"][n]["一烧合格率"]);
-                        window.DayCL.data.datasets[1].data[n] = (json["rows"][n]["一烧产量"]);
-                        window.DayCL.data.datasets[2].data[n] = (json["rows"][n]["一烧出窑量"]);
+                        window.DayCL.data.datasets[0].data[n] = (json["rows"][n]["一烧产量"]);
+                        window.DayCL.data.datasets[1].data[n] = (json["rows"][n]["一烧出窑量"]);
                     }
                     }
                     window.DayCL.update();
             });
+
+
+			$.get("Boardkanban.ashx?m=rate", function (data) {
+				clearData2();
+				var json = JSON.parse(data);
+				if (json["success"] == true) {
+					for (var n = 0; n < json["rows"].length; n++) {
+						window.MonthCL.data.labels.push(json["rows"][n]["SJ"]);
+						window.MonthCL.data.datasets[0].data[n] = (json["rows"][n]["一烧合格率"]);
+					}
+				}
+				window.MonthCL.update();
+			});
+
+
+
+
         }
         function initData() {
             window.chartColors = {
@@ -329,9 +355,8 @@
             window.randomScalingFactor = function (num) {
                 return Math.round(Math.random() * num);
             }
-
             Chart.defaults.global.defaultFontColor = 'white';
-            Chart.defaults.global.defaultFontSize = 16;
+            Chart.defaults.global.defaultFontSize = 13;
             Chart.defaults.global.legend.display = false;
 
             //每小时产量=========================================
@@ -339,22 +364,14 @@
 				data: {
 					labels: [],
 					datasets: [
-						{
-							label: "一烧合格率%",
+					{
+							label: "一烧产量",
 							fill: false,
 							backgroundColor: color(window.chartColors.red).alpha(0.6).rgbString(),
 							borderColor: window.chartColors.red,
 							borderWidth: 2,
 							pointRadius: 15,
 							data: []
-						}, {
-							label: "一烧产量",
-							fill: false,
-							backgroundColor: color(window.chartColors.orange).alpha(0.6).rgbString(),
-							borderColor: window.chartColors.orange,
-							borderWidth: 2,
-							pointRadius: 15,
-							data: []
                         },
 						{
 							label: "一烧出窑量",
@@ -406,9 +423,82 @@
             var ctxDayCL = document.getElementById("canvasDayCL").getContext("2d");
             window.DayCL = new Chart(ctxDayCL, configDayCL);
         }
+		function initData2() {
+			window.chartColors = {
+				red: 'rgb(255, 99, 132)',
+				orange: 'rgb(255, 159, 64)',
+				yellow: 'rgb(255, 250, 86)',
+				green: 'rgb(75, 192, 192)',
+				blue: 'rgb(54, 162, 250)',
+				purple: 'rgb(153, 102, 255)',
+				grey: 'rgb(231,233,237)'
+			};
 
-    </script>
+			var color = Chart.helpers.color;
+			window.randomScalingFactor = function (num) {
+				return Math.round(Math.random() * num);
+			}
+			Chart.defaults.global.defaultFontColor = 'white';
+			Chart.defaults.global.defaultFontSize = 13;
+			Chart.defaults.global.legend.display = false;
 
+			//甲班缺陷===========================================
+			window.configMonthCL = {
+				data: {
+					labels: [],
+					datasets: [
+						{
+							label: "一烧合格率%",
+							fill: false,
+							backgroundColor: color(window.chartColors.red).alpha(0.6).rgbString(),
+							borderColor: window.chartColors.red,
+							borderWidth: 2,
+							pointRadius: 15,
+							data: []
+						}
+					]
+				},
+				type: 'line',
+				options: {
+					responsive: true,
+					legend: {
+						display: true
+					},
+					title: {
+						display: false,
+						text: '每小时产量'
+					},
+					tooltips: {
+						mode: 'index',
+						intersect: false,
+					},
+					hover: {
+						mode: 'nearest',
+						intersect: true
+					},
+					scales: {
+						xAxes: [{
+							display: true,
+							scaleLabel: {
+								display: false,
+								labelString: ''
+							}
+						}],
+						yAxes: [{
+							display: true,
+							scaleLabel: {
+								display: false,
+								labelString: 'Value'
+							}
+						}]
+					}
+				}
+			};
+			var ctxMonthCL = document.getElementById("canvasMonthCL").getContext("2d");
+			window.MonthCL = new Chart(ctxMonthCL, configMonthCL);
+			//===================================================
+		}
+    </script>
     <script src="/Plugins/chartjs-2.8.0/chart-2.8.min.js"></script>
     <script src="/Plugins/chartjs-2.8.0/chartjs-plugin-datalabels.js"></script>
     <script src="/Plugins/chartjs-2.8.0/utils.js"></script>

+ 4 - 5
wwwroot/main/Procedure/BurnIntoKanban/BurnIntoKanban.ashx

@@ -255,8 +255,7 @@ public class FormingKanban : IHttpHandler, IReadOnlySessionState
 							
 																				UNION ALL
 												
-															SELECT COUNT(*) 库存 FROM TP_PM_INPRODUCTION WHERE VALUEFLAG=1
-																	AND CREATETIME 	 >={first} AND CREATETIME <  {second} "	 .Replace("{first}",first).Replace("{second}",second);
+															SELECT COUNT(*) 库存 FROM TP_PM_INPRODUCTION WHERE VALUEFLAG=1 AND PROCEDUREID=11"	 .Replace("{first}",first).Replace("{second}",second);
                 //直接获取不分页数据
                 DataTable dt = conn.ExecuteDatatable(sqlStr);
                 string jsonStr = new JsonResult(dt).ToJson();
@@ -342,8 +341,8 @@ public class FormingKanban : IHttpHandler, IReadOnlySessionState
 												缺陷.缺陷名称,
 												缺陷.缺陷数量,
 												其他缺陷.其他缺陷数量  AS 其他缺陷数量,
-												DECODE( NVL( 缺陷.缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 缺陷.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.0' ) || '%' ) 缺陷率,
-												DECODE( NVL( 其他缺陷.其他缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 其他缺陷.其他缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.0' ) || '%' ) 其他缺陷率
+												DECODE( NVL( 缺陷.缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 缺陷.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.00' ) || '%' ) 缺陷率,
+												DECODE( NVL( 其他缺陷.其他缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 其他缺陷.其他缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.00' ) || '%' ) 其他缺陷率
 											FROM
 												缺陷
 												LEFT JOIN 检验数 ON 1 = 1
@@ -375,7 +374,7 @@ public class FormingKanban : IHttpHandler, IReadOnlySessionState
 												)
 												SELECT
 												一烧产量.出窑数 ,
-												DECODE( NVL( 打磨.缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 打磨.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.0' ) || '%' ) as 缺陷率
+												DECODE( NVL( 打磨.缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 打磨.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.00' ) || '%' ) as 缺陷率
 												FROM  
 												打磨
 												LEFT JOIN 检验数 on 1=1

+ 7 - 66
wwwroot/main/Procedure/BurnIntoKanban/BurnIntoKanban.html

@@ -29,7 +29,6 @@
 			<!--31天产量曲线图-->
 			<div style="width:1840px;height:40%;display:flex;flex-direction:row;">
 				<div style="width: 75%; height: 150px;">
-					<div style="color:white;font-size:15px;font-weight:600; text-align:center">每日产量计划达成</div>
 					<canvas id="canvasDayCL" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 170px; width: 100% "></canvas>
 				</div>
 			</div>
@@ -45,13 +44,13 @@
 						<td style="width: 8%; height: 60px; font-size: 30px; text-align: left" colspan="2"><strong><span id="sj" style="color:white;">2023-4-30 00:00</span></strong></td>
 					</tr>
 					<tr class="tr_title_warning">
-						<td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">装窑:<span id="ydm" style="color:white;">加载中...</span></td>
+						<td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">装窑&nbsp;&nbsp;&nbsp;<span id="ydm" style="color:white;"> 加载中...</span></td>
 					</tr>
 					<tr class="tr_title_warning">
-						<td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">白坯入库:<span id="ycx" style="color:white;">加载中...</span></td>
+						<td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">白坯入库:<span id="ycx" style="color:white;">加载中...</span></td>
 					</tr>
 					<tr class="tr_title_warning">
-						<td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">白坏库存:<span id="ygx" style="color:white;">加载中...</span></td>
+						<td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">白坏库存:&nbsp;&nbsp;&nbsp;<span id="ygx" style="color:white;"> 加载中...</span></td>
 					</tr>
 				</table>
 			</div>
@@ -89,7 +88,7 @@
 
 					<table cellspacing="0" cellpadding="0" border="0" style="width: 50%;">
 						<tr class="tr_title_warning" style="height: 60px; font-size: 30px">
-							<td colspan="3" style="width:50%">施釉缺陷率:<span id="dmqxl" style="color:white">——</span></td>
+							<td colspan="3" style="width:50%">烧成缺陷率:<span id="dmqxl" style="color:white">——</span></td>
 							<td colspan="3" style="width:50%">一烧产量:<span id="cxqxl" style="color:white">——</span></td>
 						</tr>
 						<tr class="tr_bg_light_warning" style="height: 50px; font-size: 25px">
@@ -368,7 +367,7 @@
 							fill: false,
 							backgroundColor: color(window.chartColors.red).alpha(0.6).rgbString(),
 							borderColor: window.chartColors.red,
-							borderWidth: 4,
+							borderWidth: 2,
                             pointRadius: 15,
                             
 							data: []
@@ -412,64 +411,6 @@
             };
             var ctxDayCL = document.getElementById("canvasDayCL").getContext("2d");
             window.DayCL = new Chart(ctxDayCL, configDayCL);
-
-
-			//甲班缺陷===========================================
-			window.configMonthCL = {
-				data: {
-					labels: [],
-					datasets: [
-					 {
-							//label: "近七日整体合格率",
-							label: "日装窑量",
-							fill: false,
-							backgroundColor: color(window.chartColors.purple).alpha(0.6).rgbString(),
-							borderColor: window.chartColors.purple,
-							borderWidth: 4,
-							pointRadius: 15,
-							data: []
-						}
-					]
-				},
-				type: 'line',
-				options: {
-					responsive: true,
-					legend: {
-						display: true
-					},
-					title: {
-						display: false,
-						text: '每小时产量'
-					},
-					tooltips: {
-						mode: 'index',
-						intersect: false,
-					},
-					hover: {
-						mode: 'nearest',
-						intersect: true
-					},
-					scales: {
-						xAxes: [{
-							display: true,
-							scaleLabel: {
-								display: false,
-								labelString: ''
-							}
-						}],
-						yAxes: [{
-							display: true,
-							scaleLabel: {
-								display: false,
-								labelString: 'Value'
-							}
-						}]
-					}
-				}
-			};
-			var ctxMonthCL = document.getElementById("canvasMonthCL").getContext("2d");
-			window.MonthCL = new Chart(ctxMonthCL, configMonthCL);
-            //===================================================
         }
 		function initData2() {
 			window.chartColors = {
@@ -501,8 +442,8 @@
 							fill: false,
 							backgroundColor: color(window.chartColors.purple).alpha(0.6).rgbString(),
 							borderColor: window.chartColors.purple,
-							borderWidth: 4,
-							pointRadius: 13,
+							borderWidth: 2,
+							pointRadius: 15,
 							data: []
 						}
 					]

+ 6 - 5
wwwroot/main/Procedure/FormingKanban/FormingKanban.ashx

@@ -43,6 +43,7 @@ public class FormingKanban : IHttpHandler, IReadOnlySessionState
                         FROM TP_PM_GROUTINGDAILYDETAIL GDS
 						LEFT JOIN TP_PC_GROUTINGLINE GD ON GD.GROUTINGLINEID=GDS.GROUTINGLINEID
                         WHERE GDS.VALUEFLAG=1 and gd.VALUEFLAG=1 
+												AND GDS.GROUTINGFLAG=1
 							UNION ALL
 				SELECT
                         SUM(CASE WHEN TRUNC(  GDD.CREATETIME) = trunc(sysdate)  AND gd.HIGHPRESSUREFLAG=0 	and gdd.PROCEDUREID=7 AND SUBSTR(GDD.GROUTINGLINECODE, 2,1)='A'THEN 1 ELSE 0 END   ) 成型A交坯数量,
@@ -51,7 +52,8 @@ public class FormingKanban : IHttpHandler, IReadOnlySessionState
                         SUM(CASE WHEN TRUNC(  GDD.CREATETIME) = trunc(sysdate)  AND gd.HIGHPRESSUREFLAG=1 	 and gdd.PROCEDUREID=7 THEN 1 ELSE 0 END  ) 高压交坯数量
 						FROM TP_PM_PRODUCTIONDATA GDD
 						LEFT JOIN TP_PC_GROUTINGLINE GD ON GD.GROUTINGLINEID=GDD.GROUTINGLINEID
-                        WHERE gdd.VALUEFLAG=1 and gd.VALUEFLAG=1";
+                        WHERE gdd.VALUEFLAG=1 and gd.VALUEFLAG=1
+											";
                 //直接获取不分页数据
                 DataTable dt = conn.ExecuteDatatable(sqlStr);
                 string jsonStr = new JsonResult(dt).ToJson();
@@ -130,7 +132,6 @@ public class FormingKanban : IHttpHandler, IReadOnlySessionState
 															TP_PM_GROUTINGDAILYDETAIL 
 															WHERE VALUEFLAG=1
 															AND GROUTINGFLAG=1
-															AND SCRAPFLAG=0 
 															AND GROUTINGDATE >= {first} AND GROUTINGDATE < 	{second}
 															GROUP BY TO_CHAR(GROUTINGDATE,'MM-DD')
 														)
@@ -173,7 +174,7 @@ public class FormingKanban : IHttpHandler, IReadOnlySessionState
 												THEN 100
 												ELSE
 												(NVL( 半检缺陷.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100 
-												END,'fm99990.0' ) || '%' ) as 缺陷率
+												END,'fm99990.00' ) || '%' ) as 缺陷率
 												FROM  
 												半检缺陷
 												LEFT JOIN 检验数 on 1=1
@@ -332,11 +333,11 @@ public class FormingKanban : IHttpHandler, IReadOnlySessionState
 												DECODE( NVL( 缺陷.缺陷数量, 0 ), 0,'0%', TO_CHAR( 
 												CASE WHEN 	( NVL( 缺陷.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100>=100 THEN 100
 												ELSE
-												( NVL( 缺陷.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100 END ,'fm99990.0' ) || '%' )  as  缺陷率,
+												( NVL( 缺陷.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100 END ,'fm99990.00' ) || '%' )  as  缺陷率,
 												DECODE( NVL( 其他缺陷.其他缺陷数量, 0 ),0,'0%',TO_CHAR(
 												CASE WHEN 	(NVL( 其他缺陷.其他缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100>=100
 												THEN 100
-												ELSE 	(NVL( 其他缺陷.其他缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100 END,'fm99990.0' ) || '%' ) 其他缺陷率 
+												ELSE 	(NVL( 其他缺陷.其他缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100 END,'fm99990.00' ) || '%' ) 其他缺陷率 
 											FROM
 												缺陷
 												LEFT JOIN 检验数 ON 1 = 1

+ 10 - 5
wwwroot/main/Procedure/FormingKanban/FormingKanban.html

@@ -29,7 +29,7 @@
             <!--31天产量曲线图-->
             <div style="width:1840px;height:30%;display:flex;flex-direction:row;">
                 <div style="width: 80%; height: 300px;">
-                    <div style="color:white;font-size:15px;font-weight:600; text-align:center">每日产量计划达成</div>
+                   
                     <canvas id="canvasDayCL" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 330px; width: 90% "></canvas>
                 </div>
             </div>
@@ -48,12 +48,17 @@
                 </table>
             </div>
             <!--表格-->
-            <div style="width: 100%; height: 530px; display: flex; flex-direction: row; margin-top: 4%">
-                <div style="width: 50%; height: 530px; padding-right: 20px;">
+            <div style="width: 100%; height: 530px; display: flex; flex-direction: row; margin-top: 3%">
+                <table cellspacing="0" cellpadding="0" border="0" style="width: 49%; height: 30px;">
+                    <tr class="tr_title_warning" style="height: 60px; font-size:27px">
+                     <td style="color:white;">成型工序当日注浆量,交坯量</td>
+                    </tr>
+                </table>
+                <div style="width: 50%; height: 530px; padding-right: 20px;margin-left:-49%;margin-top:50px">
                     <table cellspacing="0" cellpadding="0" border="0" style="width:100%;">
                         <tr class="tr_title_warning" style="height: 60px; font-size:27px">
                             <td rowspan="2">成型A </td>
-                            <td clospan="2" style="text-align :left " ><span id="cxaj" style="color:white;">交坯量:0</span></td>
+                            <td clospan="2" style="text-align :left "><span id="cxaj" style="color:white;">交坯量:0</span></td>
                             <td rowspan="2">成型B</td>
                             <td clospan="2" style="text-align :left"><span id="cxbj" style="color:white;">交坯量:0</span></td>
                         </tr>
@@ -74,7 +79,7 @@
                         </tr>
                     </table>
 
-                    <table cellspacing="0" cellpadding="0" border="0" style="width: 100%; margin-top: 5%;">
+                    <table cellspacing="0" cellpadding="0" border="0" style="width: 100%;">
                         <tr class="tr_title_warning" style="height: 40px; font-size: 30px">
                             <td colspan="3">成型缺陷率:<span id="cqxl" style="color: white; font-size: 35px">——</span></td>
                             <td colspan="3">一烧产量:<span id="scl" style="color: white; font-size: 35px ">——</span></td>

+ 3 - 3
wwwroot/main/Procedure/GlazedKanban/GlazedKanban.ashx

@@ -346,8 +346,8 @@ SELECT
 												缺陷.缺陷数量,
 												NVL(其他缺陷.其他缺陷数量, 0) AS 其他缺陷数量,
 
-												DECODE( NVL( 缺陷.缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 缺陷.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.0' ) || '%' ) 缺陷率,
-												DECODE( NVL( 其他缺陷.其他缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 其他缺陷.其他缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.0' ) || '%' ) 其他缺陷率
+												DECODE( NVL( 缺陷.缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 缺陷.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.00' ) || '%' ) 缺陷率,
+												DECODE( NVL( 其他缺陷.其他缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 其他缺陷.其他缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.00' ) || '%' ) 其他缺陷率
 											FROM
 												缺陷
 												LEFT JOIN 检验数 ON 1 = 1
@@ -378,7 +378,7 @@ SELECT
 												)
 												SELECT
 												一烧产量.出窑数 ,
-												DECODE( NVL( 施釉.缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 施釉.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.0' ) || '%' ) as 施釉缺陷率
+												DECODE( NVL( 施釉.缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 施釉.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.00' ) || '%' ) as 施釉缺陷率
 												FROM  
 												施釉
 												LEFT JOIN 检验数 on 1=1

+ 10 - 9
wwwroot/main/Procedure/GlazedKanban/GlazedKanban.html

@@ -28,25 +28,26 @@
 
             <!--31天产量曲线图-->
             <div style="width:1840px;height:30%;display:flex;flex-direction:row;">
-                <div style="width: 75%; height: 300px;">
-                    <div style="color:white;font-size:15px;font-weight:600; text-align:center">每日产量计划达成</div>
-                    <canvas id="canvasDayCL" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 330px; width: 80% "></canvas>
+                <div style="width: 75%; height: 280px;">
+                   
+                    <canvas id="canvasDayCL" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 300px; width: 80% "></canvas>
                 </div>
             </div>
 
             <div>
-                <table rules="none" align="right" style="width: 20%; height: 270px; margin-left:80%;margin-top:-291px ">
+                <table rules="none" align="right" style="width: 25%; height: 270px; margin-left:80%;margin-top:-321px ">
                     <tr class="tr_title_warning">
-                        <td style="width: 8%; height: 60px; font-size: 30px; text-align: left" colspan="2"><strong><span id="sj" style="color:white;">2023-4-30 00:00:00</span></strong></td>
+                        <td style="width: 8%; height: 60px; font-size: 25px; text-align: left" colspan="2"><strong><span id="sj" style="color:white;">2023-4-30 00:00:00</span></strong></td>
                     </tr>
                     <tr class="tr_title_warning">
-                        <td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">月人工:<span id="ydm"  style="color:white;">加载中...</span></td>
+                        <td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">月人工施釉量&nbsp;&nbsp;&nbsp;<span id="ydm" style="color:white;"> 加载中...</span></td>
                     </tr>
                     <tr class="tr_title_warning">
-                        <td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">月机械手:<span id="ycx" style="color:white;">加载中...</span></td>
+                        <td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">月机械手施釉量:<span id="ycx" style="color:white;">加载中...</span></td>
                     </tr>
                     <tr class="tr_title_warning">
-                        <td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">月合计:<span id="ygx"   style="color:white;">加载中...</span></td>
+                        <td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">月度合计:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
+                        <span id="ygx" style="color:white;">加载中...</span></td>
                     </tr>
                 </table>
             </div>
@@ -332,7 +333,7 @@
             }
 
             Chart.defaults.global.defaultFontColor = 'white';
-            Chart.defaults.global.defaultFontSize = 16;
+            Chart.defaults.global.defaultFontSize = 13;
             Chart.defaults.global.legend.display = false;
 
             //每小时产量=========================================

+ 3 - 3
wwwroot/main/Procedure/HalfCheckKanban/HalfCheckKanban.ashx

@@ -60,7 +60,7 @@ public class FormingKanban : IHttpHandler, IReadOnlySessionState
 												DECODE( NVL( 半检缺陷.缺陷数量, 0 ),0,'0%',TO_CHAR(
 												CASE WHEN (NVL( 半检缺陷.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100 >=100
 												THEN 100 else  (NVL( 半检缺陷.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100 END
-												,'fm99990.0' ) || '%' ) as 缺陷率
+												,'fm99990.00' ) || '%' ) as 缺陷率
 												FROM  
 												半检缺陷
 												LEFT JOIN 检验数 on 1=1
@@ -364,12 +364,12 @@ public class FormingKanban : IHttpHandler, IReadOnlySessionState
 												CASE WHEN 	(NVL( 缺陷.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100 >=100
 												THEN 100
 												ELSE 	(NVL( 缺陷.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100 END
-											,'fm99990.0' ) || '%' ) 缺陷率,
+											,'fm99990.00' ) || '%' ) 缺陷率,
 												DECODE( NVL( 其他缺陷.其他缺陷数量, 0 ),0,'0%',TO_CHAR(
 												CASE WHEN (NVL( 其他缺陷.其他缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100>=100
 												THEN 100
 												ELSE (NVL( 其他缺陷.其他缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100 END
-												,'fm99990.0' ) || '%' ) 其他缺陷率
+												,'fm99990.00' ) || '%' ) 其他缺陷率
 											FROM
 												缺陷
 												LEFT JOIN 检验数 ON 1 = 1

+ 4 - 4
wwwroot/main/Procedure/HalfCheckKanban/HalfCheckKanban.html

@@ -29,7 +29,7 @@
             <!--31天产量曲线图-->
             <div style="width:1840px;height:30%;display:flex;flex-direction:row;">
                 <div style="width: 80%; height: 300px;">
-                    <div style="color:white;font-size:15px;font-weight:600; text-align:center">每日产量计划达成</div>
+                   
                     <canvas id="canvasDayCL" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 330px; width: 80% "></canvas>
                 </div>
             </div>
@@ -45,10 +45,10 @@
                         <td style="width: 8%; height: 75px; font-size: 35px; text-align: left ">月出库量:<span id="yck" style="color:white;">加载中...</span></td>
                     </tr>
                     <tr class="tr_bg_dark_warning">
-                        <td style="width: 8%; height: 75px; font-size: 35px; text-align: left ">精坯库存:<span id="kc" style="color:white;">加载中...</span></td>
+                        <td style="width: 8%; height: 70px; font-size: 35px; text-align: left ">月检验量:<span id="yjyl" style="color:white;">加载中...</span></td>
                     </tr>
                     <tr class="tr_bg_dark_warning">
-                        <td style="width: 8%; height: 70px; font-size: 35px; text-align: left ">月检验量:<span id="yjyl" style="color:white;">加载中...</span></td>
+                        <td style="width: 8%; height: 75px; font-size: 35px; text-align: left ">精坯库存:<span id="kc" style="color:white;">加载中...</span></td>
                     </tr>
                 </table>
             </div>
@@ -384,7 +384,7 @@
 							data: []
 						}]
                 },
-                type: 'bar',
+                type: 'line',
                 options: {
                     responsive: true,
                     legend: {

+ 1 - 1
wwwroot/main/Procedure/PackagingKanban/PackagingKanban.html

@@ -25,7 +25,7 @@
             <!--31天产量曲线图-->
             <div style="width:1840px;height:30%;display:flex;flex-direction:row;">
                 <div style="width: 80%; height: 300px;">
-                    <div style="color:white;font-size:15px;font-weight:600; text-align:center">每日产量计划达成</div>
+                   
                     <canvas id="canvasDayCL" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 330px; width: 80% "></canvas>
                 </div>
             </div>

+ 4 - 4
wwwroot/main/Procedure/RefinementKanban/RefinementKanban.ashx

@@ -404,13 +404,13 @@ public class  FormingKanban : IHttpHandler, IReadOnlySessionState
 												THEN 100
 												else 
 												(NVL( 缺陷.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100
-												END ,'fm99990.0' ) || '%' ) 缺陷率,
+												END ,'fm99990.00' ) || '%' ) 缺陷率,
 												DECODE( NVL( 其他缺陷.其他缺陷数量, 0 ),0,'0%',TO_CHAR(
 												CASE  WHEN ((NVL( 其他缺陷.其他缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100)>=100
 												THEN 100
 												ELSE
 												(NVL( 其他缺陷.其他缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100
-												END ,'fm99990.0' ) || '%' ) 其他缺陷率
+												END ,'fm99990.00' ) || '%' ) 其他缺陷率
 											FROM
 												缺陷
 												LEFT JOIN 检验数 ON 1 = 1
@@ -451,8 +451,8 @@ public class  FormingKanban : IHttpHandler, IReadOnlySessionState
 												)
 												SELECT
 												一烧产量.出窑数 ,
-												DECODE( NVL( 打磨.缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 打磨.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.0' ) || '%' ) as 打磨缺陷率,
-												DECODE( NVL( 擦洗.缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 擦洗.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.0' ) || '%' ) as 擦洗缺陷率
+												DECODE( NVL( 打磨.缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 打磨.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.00' ) || '%' ) as 打磨缺陷率,
+												DECODE( NVL( 擦洗.缺陷数量, 0 ),0,'0%',TO_CHAR((NVL( 擦洗.缺陷数量, 0 ) / DECODE( NVL( 检验数.一烧出窑数, 1 ), 0, 1, NVL( 检验数.一烧出窑数, 1 ) ) ) * 100,'fm99990.00' ) || '%' ) as 擦洗缺陷率
 												FROM  
 												打磨
 												LEFT JOIN 检验数 on 1=1

+ 146 - 48
wwwroot/main/Procedure/RefinementKanban/RefinementKanban.html

@@ -28,43 +28,52 @@
 
             <!--31天产量曲线图-->
             <div style="width:1840px;height:30%;display:flex;flex-direction:row;">
-                <div style="width: 75%; height: 300px;">
-                    <div style="color:white;font-size:15px;font-weight:600; text-align:center">每日产量计划达成</div>
-                    <canvas id="canvasDayCL" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 330px; width: 80% "></canvas>
+                <div style="width: 82%; height: 150px;">
+                    <canvas id="canvasDayCL" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 160px; width: 100% "></canvas>
+                </div>
+            </div>
+
+            <div style="width:1840px;height:40%;display:flex;flex-direction:row; margin-top:-7%">
+                <div style="width: 82%; height: 150px;">
+                    <canvas id="canvasMonthDayCL" style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select: none; height: 170px; width: 100%;"></canvas>
                 </div>
             </div>
 
             <div>
-                <table rules="none" align="right" style="width: 20%; height: 270px; margin-left:80%;margin-top:-291px ">
+                <table rules="none" align="right" style="width: 18%; height: 270px; margin-left:80%;margin-top:-30%">
                     <tr class="tr_title_warning">
-                        <td style="width: 8%; height: 60px; font-size: 30px; text-align: left" colspan="2" ><strong><span id="sj" style="color:white;">2023-4-30 00:00:00</span></strong></td>
+                        <td style="width: 8%; height: 60px; font-size: 25px; text-align: left" colspan="2"><strong><span id="sj" style="color:white;">2023-4-30 00:00:00</span></strong></td>
                     </tr>
                     <tr class="tr_title_warning">
-                        <td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">月打磨:<span id="ydm" style="color:white;">加载中...</span></td>
+                        <td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">月打磨:<span id="ydm" style="color:white;">加载中...</span></td>
                     </tr>
                     <tr class="tr_title_warning">
-                        <td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">月擦洗:<span id="ycx" style="color:white;">加载中...</span></td>
+                        <td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">月擦洗:<span id="ycx" style="color:white;">加载中...</span></td>
                     </tr>
                     <tr class="tr_title_warning">
-                        <td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">月改洗:<span id="ygx" style="color:white;">加载中...</span></td>
+                        <td style="width: 8%; height: 95px; font-size: 35px; text-align: left ">月改洗:<span id="ygx" style="color:white;">加载中...</span></td>
                     </tr>
                 </table>
             </div>
             <!--表格-->
-            <div style="width: 100%; height: 530px; display: flex; flex-direction: row; margin-top: 4%">
-                <div style="width: 100%; height: 530px; ">
+            <div style="width: 100%; height: 500px; display: flex; flex-direction: row; margin-top: -10%">
+                <div style="width: 100%; height: 500px; ">
                     <table cellspacing="0" cellpadding="0" border="0" style="width:50%;">
+                        <tr class="tr_title_warning">
+                            <td colspan="7" style="font-size: 30px; color: white;">精修工序个人数据</td>
+                        </tr>
                         <tr class="tr_title_warning" style="height: 30px; font-size:27px">
-                            <td  style="width: 15%;text-align:center">工号</td>
-                            <td  style="width: 15%; text-align: center">数量</td>
-                            <td  style="width: 15%; text-align: center">工号</td>
-                            <td  style="width: 15%; text-align: center">数量</td>
-                            <td  style="width: 15%; text-align: center">工号</td>
-                            <td  style="width: 15%;text-align:center">数量</td>
+                            <td style="width: 15%;text-align:center">工号</td>
+                            <td style="width: 15%; text-align: center">数量</td>
+                            <td style="width: 15%; text-align: center">工号</td>
+                            <td style="width: 15%; text-align: center">数量</td>
+                            <td style="width: 15%; text-align: center">工号</td>
+                            <td style="width: 15%;text-align:center">数量</td>
                         </tr>
                     </table>
-                    <div style=" height:170px;overflow:hidden;">
-                        <table style="width: 50%; display:none;" id="StaffTable_template"> <!--style=""-->
+                    <div style=" height:158px;overflow:hidden;">
+                        <table style="width: 50%; display:none;" id="StaffTable_template">
+                            <!--style=""-->
                             <tr class="tr_title_warning" style="height: 30px; font-size: 20px">
                                 <td style="font-size: 18px; color: white; height: 30px; width: 16%; text-align: center ">{工号}</td>
                                 <td style="font-size: 20px; color: white; height: 30px; width: 16%; text-align: center ">{数量}</td>
@@ -83,8 +92,8 @@
                             <td colspan="6">一烧产量:<span id="scl" style="color:white;">:——</span></td>
                         </tr>
                         <tr class="tr_title_warning" style="height: 50px; font-size: 30px">
-                            <td colspan="3"style="width:50%">打磨缺陷率:<span id="dmqxl" style="color:white;">——</span></td>
-                            <td colspan="3"style="width:50%">擦洗缺陷率:<span id="cxqxl" style="color:white;">——</span></td>
+                            <td colspan="3" style="width:50%">打磨缺陷率:<span id="dmqxl" style="color:white;">——</span></td>
+                            <td colspan="3" style="width:50%">擦洗缺陷率:<span id="cxqxl" style="color:white;">——</span></td>
                         </tr>
                         <tr class="tr_bg_light_warning" style="height: 50px; font-size: 25px">
                             <td>缺陷</td>
@@ -113,7 +122,7 @@
                     </table>
                 </div>
             </div>
-            <div style="width: 52%; height: 500px; padding-right: 20px; margin-top: -530px; margin-left: 50% ">
+            <div style="width: 52%; height: 500px; padding-right: 20px; margin-top: -500px; margin-left: 50% ">
                 <table cellspacing="0" cellpadding="0" border="0" style="width:100%;">
                     <tr class="tr_title_warning">
                         <td colspan="4" style="color: white; font-size: 30px;">成检实时数据(精修工序缺陷数据)</td>
@@ -125,7 +134,7 @@
                         <td style="font-size: 27px; width: 25%; height: 30px; ">产品分级</td>
                     </tr>
                 </table>
-                <div style=" height: 418px; overflow: hidden;">
+                <div style=" height: 468px; overflow: hidden;">
                     <table id="dayTable_template" style="display:none;">
                         <tr class="tr_bg_light_warning" style="height:30px;">
                             <td style="font-size: 18px; width: 25%; height: 30px; ">{责任工号}</td>
@@ -134,7 +143,7 @@
                             <td style="font-size: 18px; width: 25%; height: 30px; ">{产品分级}</td>
                         </tr>
                     </table>
-                    <table id="dayTable"  style="width: 100%; ">
+                    <table id="dayTable" style="width: 100%; ">
                     </table>
                 </div>
             </div>
@@ -156,7 +165,9 @@
         //页面加载  
         $(document).ready(function () {
             loadData();
+			loadData2();
             initData();
+			initData2();
             clearData();
             timeUp();
             StaffTable();
@@ -268,12 +279,18 @@
         function clearData() {
             //清除数据
             window.DayCL.data.labels = [];
-            //window.DayCL.data.datasets[0].data = [0, 0, 0, 0, 0, 0, 0];
             window.DayCL.data.datasets[0].data = [];
-            //window.DayCL.data.datasets[1].data = [0, 0, 0, 0, 0, 0, 0];
-            window.DayCL.data.datasets[1].data = [];
             window.DayCL.update();
+
         }
+
+		function clearData2() {
+			//清除数据
+			window.MonthDayCL.data.labels = [];
+			window.MonthDayCL.data.datasets[0].data = [];
+			window.MonthDayCL.data.datasets[1].data = [];
+			window.MonthDayCL.update();
+		}
 		function loadServerTime() {
 			$.get('RefinementKanban.ashx?m=fwq', function (data) {
 				var json = JSON.parse(data);
@@ -307,13 +324,111 @@
                     for (var n = 0; n < json["rows"].length; n++) {
                         window.DayCL.data.labels.push(json["rows"][n]["SJ"]);
                         window.DayCL.data.datasets[0].data[n] = (json["rows"][n]["打磨"]);
-                        window.DayCL.data.datasets[1].data[n] = (json["rows"][n]["擦洗"]);
-						window.DayCL.data.datasets[2].data[n] = (json["rows"][n]["改洗"]);
                     }
                     }
                     window.DayCL.update();
             });
         }
+
+		function loadData2() {
+			$.get("RefinementKanban.ashx?m=rate", function (data) {
+				clearData2();
+				var json = JSON.parse(data);
+				if (json["success"] == true) {
+					for (var n = 0; n < json["rows"].length; n++) {
+						window.MonthDayCL.data.labels.push(json["rows"][n]["SJ"]);
+                        window.MonthDayCL.data.datasets[0].data[n] = (json["rows"][n]["擦洗"]);
+						window.MonthDayCL.data.datasets[1].data[n] = (json["rows"][n]["改洗"]);
+					}
+				}
+				window.MonthDayCL.update();
+			});
+		}
+
+		function initData2() {
+			window.chartColors = {
+				red: 'rgb(255, 99, 132)',
+				orange: 'rgb(255, 159, 64)',
+				yellow: 'rgb(255, 250, 86)',
+				green: 'rgb(75, 192, 192)',
+				blue: 'rgb(54, 162, 250)',
+				purple: 'rgb(153, 102, 255)',
+				grey: 'rgb(231,233,237)'
+			};
+
+			var color = Chart.helpers.color;
+
+			window.randomScalingFactor = function (num) {
+				return Math.round(Math.random() * num);
+			}
+
+			Chart.defaults.global.defaultFontColor = 'white';
+			Chart.defaults.global.defaultFontSize = 13;
+			Chart.defaults.global.legend.display = false;
+
+			//每小时产量=========================================
+			window.configMonthDayCL = {
+				data: {
+					labels: [],
+					datasets: [ {
+						label: "擦洗量",
+						fill: false,
+						backgroundColor: color(window.chartColors.blue).alpha(0.6).rgbString(),
+						borderColor: window.chartColors.blue,
+						borderWidth: 2,
+						pointRadius: 13,
+						data: []
+					},
+					{
+						label: "改洗量",
+						fill: false,
+						backgroundColor: color(window.chartColors.green).alpha(0.6).rgbString(),
+						borderColor: window.chartColors.green,
+						borderWidth: 2,
+						pointRadius: 13,
+						data: []
+					}]
+				},
+				type: 'line',
+				options: {
+					responsive: true,
+					legend: {
+						display: true
+					},
+					title: {
+						display: false,
+						text: '每小时产量'
+					},
+					tooltips: {
+						mode: 'index',
+						intersect: false,
+					},
+					hover: {
+						mode: 'nearest',
+						intersect: true
+					},
+					scales: {
+						xAxes: [{
+							display: true,
+							scaleLabel: {
+								display: false,
+								labelString: ''
+							}
+						}],
+						yAxes: [{
+							display: true,
+							scaleLabel: {
+								display: false,
+								labelString: 'Value'
+							}
+						}]
+					}
+				}
+			};
+			var ctxMonthDayCL = document.getElementById("canvasMonthDayCL").getContext("2d");
+			window.MonthDayCL = new Chart(ctxMonthDayCL, configMonthDayCL);
+		}
+
         function initData() {
             window.chartColors = {
                 red: 'rgb(255, 99, 132)',
@@ -332,7 +447,7 @@
             }
 
             Chart.defaults.global.defaultFontColor = 'white';
-            Chart.defaults.global.defaultFontSize = 16;
+            Chart.defaults.global.defaultFontSize = 13;
             Chart.defaults.global.legend.display = false;
 
             //每小时产量=========================================
@@ -344,27 +459,10 @@
 						backgroundColor: color(window.chartColors.red).alpha(0.6).rgbString(),
                         borderColor: window.chartColors.red,
                         borderWidth: 2,
-                        pointRadius: 15,
+                        pointRadius: 13,
                         data: [],
                         fill: false,
-                    }, {
-						label: "擦洗量",
-                        fill: false,
-                        backgroundColor: color(window.chartColors.blue).alpha(0.6).rgbString(),
-                        borderColor: window.chartColors.blue,
-                        borderWidth: 2,
-                        pointRadius: 15,
-                        data: []
-                        },
-                    {
-						label: "改洗量",
-						fill: false,
-						backgroundColor: color(window.chartColors.green).alpha(0.6).rgbString(),
-                        borderColor: window.chartColors.green,
-							borderWidth: 2,
-							pointRadius: 15,
-							data: []
-						}]
+                    }]
                 },
                 type: 'line',
                 options: {