diff --git a/AMESCoreStudio.Web/Controllers/FQCController.cs b/AMESCoreStudio.Web/Controllers/FQCController.cs index ff62e0a9..05cffe7b 100644 --- a/AMESCoreStudio.Web/Controllers/FQCController.cs +++ b/AMESCoreStudio.Web/Controllers/FQCController.cs @@ -2230,7 +2230,7 @@ namespace AMESCoreStudio.Web.Controllers public async Task FQC012DAsync(string inhouseNo, int seq) { - var result = await _fqcApi.DeleteFqcInhouseDetail(inhouseNo); + var result = await _fqcApi.DeleteFqcInhouseDetail(inhouseNo, seq); var resultMaster = await _fqcApi.DeleteFqcInhouseMaster(inhouseNo, seq); diff --git a/AMESCoreStudio.Web/Controllers/PCSController.cs b/AMESCoreStudio.Web/Controllers/PCSController.cs index 577f39ff..94fbed14 100644 --- a/AMESCoreStudio.Web/Controllers/PCSController.cs +++ b/AMESCoreStudio.Web/Controllers/PCSController.cs @@ -8153,10 +8153,14 @@ namespace AMESCoreStudio.Web.Controllers { if (SopVer.Msg == "N") { - var GetSopVer = await _pcsApi.GetDocEsopViewByNo(item.SOPName); - if (GetSopVer.Count != 0) + ViewBag.SOPVer = _configuration["SOPVer"]; + if (ViewBag.SOPVer == null) { - item.SOPVer = GetSopVer.FirstOrDefault().document_version; + var GetSopVer = await _pcsApi.GetDocEsopViewByNo(item.SOPName); + if (GetSopVer.Count != 0) + { + item.SOPVer = GetSopVer.FirstOrDefault().document_version; + } } } } diff --git a/AMESCoreStudio.Web/Controllers/QRSController.cs b/AMESCoreStudio.Web/Controllers/QRSController.cs index 9ffa6aa5..26464800 100644 --- a/AMESCoreStudio.Web/Controllers/QRSController.cs +++ b/AMESCoreStudio.Web/Controllers/QRSController.cs @@ -773,7 +773,7 @@ namespace AMESCoreStudio.Web.Controllers } if (!string.IsNullOrWhiteSpace(factoryNo)) - LineItems = LineItems.Where(w => w.Text == factoryNo).ToList(); + LineItems = LineItems.Where(w => w.Text.ToUpper().Trim().Contains(factoryNo.Trim().ToUpper())).ToList(); ViewBag.LineList = LineItems; } diff --git a/AMESCoreStudio.Web/HttpApis/AMES/IFQC.cs b/AMESCoreStudio.Web/HttpApis/AMES/IFQC.cs index e656acdc..0635fe5c 100644 --- a/AMESCoreStudio.Web/HttpApis/AMES/IFQC.cs +++ b/AMESCoreStudio.Web/HttpApis/AMES/IFQC.cs @@ -607,8 +607,8 @@ namespace AMESCoreStudio.Web /// 刪除FQC 表身 /// /// - [WebApiClient.Attributes.HttpDelete("api/FqcInhouseDetail/{id}")] - ITask> DeleteFqcInhouseDetail(string id); + [WebApiClient.Attributes.HttpDelete("api/FqcInhouseDetail/{no}/{seq}")] + ITask> DeleteFqcInhouseDetail(string no, int seq); #endregion } diff --git a/AMESCoreStudio.Web/Views/PCS/PCS001R.cshtml b/AMESCoreStudio.Web/Views/PCS/PCS001R.cshtml index ef396398..b98c0c34 100644 --- a/AMESCoreStudio.Web/Views/PCS/PCS001R.cshtml +++ b/AMESCoreStudio.Web/Views/PCS/PCS001R.cshtml @@ -494,9 +494,18 @@
- - - + + +
@@ -512,7 +521,10 @@
- +
@@ -533,7 +545,10 @@
- +
@@ -546,7 +561,10 @@
- +
@@ -562,7 +580,10 @@
- +
@@ -722,7 +743,7 @@
-
+
@@ -866,7 +887,10 @@
- +
@@ -966,6 +990,7 @@ @*檔案路徑*@ SOP類型 生產單位 + SOP版本 @@ -973,18 +998,20 @@ { - @index.SOPName @* - @index.SOPPath - *@ + @index.SOPPath + *@ @index.SOPTypeName @index.UnitNoName + + @index.SOPVer + l++; } diff --git a/AMESCoreStudio.Web/Views/PCS/PCS003.cshtml b/AMESCoreStudio.Web/Views/PCS/PCS003.cshtml index de4a1fa2..c735d5ba 100644 --- a/AMESCoreStudio.Web/Views/PCS/PCS003.cshtml +++ b/AMESCoreStudio.Web/Views/PCS/PCS003.cshtml @@ -1021,6 +1021,9 @@ 生產單位 + + SOP版本 + @@ -1043,6 +1046,9 @@ + + + 刪除 @@ -1748,6 +1754,7 @@ /* '' +*/ '' + SelectSOPType + '' + '' + Select + '' + + ' ' + '刪除' + ''; $('#SopTable').append(contactdiv); diff --git a/AMESCoreStudio.Web/Views/PCS/PCS034.cshtml b/AMESCoreStudio.Web/Views/PCS/PCS034.cshtml index c7dbf3cb..29feeda1 100644 --- a/AMESCoreStudio.Web/Views/PCS/PCS034.cshtml +++ b/AMESCoreStudio.Web/Views/PCS/PCS034.cshtml @@ -1004,6 +1004,9 @@ 生產單位 + + SOP版本 + @@ -1026,6 +1029,9 @@ + + + 刪除 @@ -1639,6 +1645,7 @@ /* '' +*/ '' + SelectSOPType + '' + '' + Select + '' + + ' ' + '刪除' + ''; $('#SopTable').append(contactdiv); diff --git a/AMESCoreStudio.WebApi/Controllers/AMES/FqcInhouseDetailController.cs b/AMESCoreStudio.WebApi/Controllers/AMES/FqcInhouseDetailController.cs index bfb7f2c3..dbf7e42d 100644 --- a/AMESCoreStudio.WebApi/Controllers/AMES/FqcInhouseDetailController.cs +++ b/AMESCoreStudio.WebApi/Controllers/AMES/FqcInhouseDetailController.cs @@ -267,18 +267,23 @@ namespace AMESCoreStudio.WebApi.Controllers.AMES return result; } - // DELETE: api/FqcInhouseDetail/5 - [HttpDelete("{id}")] - public async Task> DeleteFqcInhouseDetail(string id) + /// + /// 刪除入庫單 + /// + /// 入庫單號 + /// 順序 + /// + [HttpDelete("{no}/{seq}")] + public async Task> DeleteFqcInhouseDetail(string no, int seq) { ResultModel result = new ResultModel(); - var fqcInhouseDetail = await _context.FqcInhouseDetails.Where(p => p.InhouseNo == id).FirstOrDefaultAsync(); + var fqcInhouseDetail = await _context.FqcInhouseDetails.Where(p => p.InhouseNo == no && p.SeqID == seq).FirstOrDefaultAsync(); if (fqcInhouseDetail == null) - { - - return fqcInhouseDetail; - } + { + + return fqcInhouseDetail; + } _context.FqcInhouseDetails.Remove(fqcInhouseDetail); await _context.SaveChangesAsync(); diff --git a/AMESCoreStudio.WebApi/Controllers/AMES/WipSopController.cs b/AMESCoreStudio.WebApi/Controllers/AMES/WipSopController.cs index 494ad07c..1ec33548 100644 --- a/AMESCoreStudio.WebApi/Controllers/AMES/WipSopController.cs +++ b/AMESCoreStudio.WebApi/Controllers/AMES/WipSopController.cs @@ -78,6 +78,7 @@ namespace AMESCoreStudio.WebApi.Controllers.AMES SOPPath = q1.SOPPath, SOPType = q1.SOPType, UnitNo = q1.UnitNo, + SOPVer = q1.SOPVer, UnitNoName = q2.UnitName, UpdateTime = q1.UpdateDate };