From 0b0fb95a160dac3edc9614ffc79afbf8309e15dd Mon Sep 17 00:00:00 2001 From: Marvin Date: Wed, 14 Dec 2022 00:18:49 +0800 Subject: [PATCH] =?UTF-8?q?1.=E4=BF=AE=E6=94=B9FQC=E6=8A=A5=E8=A1=A8?= =?UTF-8?q?=E6=9F=A5=E8=AF=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- AMESCoreStudio.Web/Controllers/QRSController.cs | 4 ++-- AMESCoreStudio.Web/Views/QRS/QRS016B.cshtml | 2 +- .../Controllers/AMES/FqcResultMasterController.cs | 8 +++++--- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/AMESCoreStudio.Web/Controllers/QRSController.cs b/AMESCoreStudio.Web/Controllers/QRSController.cs index a1d7f75d..6f08e60e 100644 --- a/AMESCoreStudio.Web/Controllers/QRSController.cs +++ b/AMESCoreStudio.Web/Controllers/QRSController.cs @@ -1139,7 +1139,7 @@ namespace AMESCoreStudio.Web.Controllers FqcCnt = int.Parse(jo["fqcCnt"].ToString()), PassCnt = int.Parse(jo["passCnt"].ToString()), FailCnt = int.Parse(jo["failCnt"].ToString()), - Rate = int.Parse(jo["passCnt"].ToString()) * 1.0 / int.Parse(jo["fqcCnt"].ToString()) * 100.0 + Rate = double.Parse((int.Parse(jo["passCnt"].ToString()) * 1.0 / int.Parse(jo["fqcCnt"].ToString()) * 100.0).ToString("0.00")) }); } @@ -1197,7 +1197,7 @@ namespace AMESCoreStudio.Web.Controllers string end_date = param[4]; string week = param[5]; - var result = await _pcsApi.GetFQCDetailData(wip_no, item_no, model_no, start_date, end_date, week, page, limit); + var result = await _pcsApi.GetFQCDetailData(wip_no, item_no, model_no, start_date, end_date, week, 0, limit); if (result.DataTotal > 0) { diff --git a/AMESCoreStudio.Web/Views/QRS/QRS016B.cshtml b/AMESCoreStudio.Web/Views/QRS/QRS016B.cshtml index b422ea15..eca1ee41 100644 --- a/AMESCoreStudio.Web/Views/QRS/QRS016B.cshtml +++ b/AMESCoreStudio.Web/Views/QRS/QRS016B.cshtml @@ -69,7 +69,7 @@ field: 'createDate', title: '開單日', width: 90, - templet: '
{{ layui.util.toDateString(d.inputDate, "yyyy/MM/dd") }}
' + templet: '
{{ layui.util.toDateString(d.createDate, "yyyy/MM/dd") }}
' }] ]; diff --git a/AMESCoreStudio.WebApi/Controllers/AMES/FqcResultMasterController.cs b/AMESCoreStudio.WebApi/Controllers/AMES/FqcResultMasterController.cs index 28a46f12..76c5a599 100644 --- a/AMESCoreStudio.WebApi/Controllers/AMES/FqcResultMasterController.cs +++ b/AMESCoreStudio.WebApi/Controllers/AMES/FqcResultMasterController.cs @@ -79,7 +79,7 @@ namespace AMESCoreStudio.WebApi.Controllers.AMES q1.WipNo, q1.ItemNo, q1.ModelNo, - q1.QaQty, + q1.LotQty, q1.PassQty, q1.FailQty, q2.WeekOfYear @@ -109,11 +109,13 @@ namespace AMESCoreStudio.WebApi.Controllers.AMES { FQCWeek = x.Key.WeekOfYear, //FQCCnt = x.Count(), - FQCCnt = x.Sum(i => i.QaQty), + FQCCnt = x.Sum(i => i.LotQty), PassCnt = x.Sum(i => i.PassQty), FailCnt = x.Sum(i => i.FailQty) }); + g = g.OrderBy(y => y.FQCWeek); + //紀錄筆數 result.DataTotal = g.Count(); @@ -173,7 +175,7 @@ namespace AMESCoreStudio.WebApi.Controllers.AMES } if (weekCode != null && weekCode != "") { - q = q.Where(w => w.WeekOfYear == int.Parse(weekCode)); + q = q.Where(w => w.WeekOfYear.Equals(int.Parse(weekCode))); } //紀錄筆數