From 415e713b444fccc25e59ff0e1b5d72467ec20b54 Mon Sep 17 00:00:00 2001 From: wxw <Administrator@DESKTOP-5BIMHQ3> Date: 星期二, 11 二月 2025 09:05:15 +0800 Subject: [PATCH] 去掉入库单和出库单验证 --- Wms/WMS.IBLL/IBllQualityServer/IQualityInspectServer.cs | 6 +++ Wms/WMS.BLL/BllTransServer/RcsServer.cs | 11 +++-- HTML/views/QualityControl/QualityInformationFrom.html | 27 +++++++++++++ Wms/WMS.BLL/BllQualityServer/QualityInspectServer.cs | 17 ++++++++ Wms/Wms/appsettings.json | 1 Wms/Model/ModelDto/LogDto/TaskDto.cs | 5 ++ Wms/WMS.BLL/LogServer/TaskServer.cs | 10 +++-- Wms/WMS.Entity/LogEntity/LogTask.cs | 6 +++ Wms/Wms/Controllers/BllQualityController.cs | 20 ++++++++++ HTML/views/QualityControl/QualityInformation.html | 2 HTML/views/HouseWithinSetting/CRLogTask.html | 5 ++ 11 files changed, 100 insertions(+), 10 deletions(-) diff --git a/HTML/views/HouseWithinSetting/CRLogTask.html b/HTML/views/HouseWithinSetting/CRLogTask.html index 1b8b459..5240304 100644 --- a/HTML/views/HouseWithinSetting/CRLogTask.html +++ b/HTML/views/HouseWithinSetting/CRLogTask.html @@ -309,6 +309,11 @@ width: 110, align: 'center', }, { + field: 'LotNo', + title: '鎵规鍙�', + width: 110, + align: 'center', + }, { field: 'StartLocat', title: '璧峰浣嶇疆', width: 100, diff --git a/HTML/views/QualityControl/QualityInformation.html b/HTML/views/QualityControl/QualityInformation.html index ecf76b3..1646cfa 100644 --- a/HTML/views/QualityControl/QualityInformation.html +++ b/HTML/views/QualityControl/QualityInformation.html @@ -36,7 +36,7 @@ <div class="layui-inline"> <label class="layui-form-label" style="width: 60px;">鎵规鍙�</label> <div class="layui-input-inline"> - <input type="text" id="LotNo" name="LotNo" placeholder="璇疯緭鍏ョ墿鏂欏悕绉�" autocomplete="off" class="layui-input"> + <input type="text" id="LotNo" name="LotNo" placeholder="璇疯緭鍏ユ壒娆″彿" autocomplete="off" class="layui-input"> </div> </div> <!-- 鐗╂枡鍙� --> diff --git a/HTML/views/QualityControl/QualityInformationFrom.html b/HTML/views/QualityControl/QualityInformationFrom.html index b15ceca..2a29a4d 100644 --- a/HTML/views/QualityControl/QualityInformationFrom.html +++ b/HTML/views/QualityControl/QualityInformationFrom.html @@ -22,10 +22,18 @@ <input type="text" name="ASNNo" placeholder="璇疯緭鍏ュ叆搴撳崟鍙�" autocomplete="off" class="layui-input"> </div> </div> --> - <div class="layui-form-item"> + <!-- <div class="layui-form-item"> <label class="layui-form-label">鎵规鍙�</label> <div class="layui-input-block" style="width: 70%;"> <input type="text" name="LotNo" placeholder="璇疯緭鍏ユ壒娆″彿" lay-verify="required" autocomplete="off" class="layui-input"> + </div> + </div> --> + <div class="layui-form-item"> + <label class="layui-form-label">鎵规鍙�</label> + <div class="layui-input-block" style="width: 70%;"> + <select name="LotNo" id="LotNo" lay-filter="LotNo" lay-verify=""> + <option value=""></option> + </select> </div> </div> <!-- <div class="layui-form-item"> @@ -72,6 +80,23 @@ if (r != null) return unescape(r[2]); return null; } + + //鑾峰彇鎵规涓嬫媺妗嗕俊鎭� + sendData(IP + "/BllQuality/GetLotNoList", {}, 'get', function(res) { + if (res.code == 0) { //鎴愬姛 + for (var i = 0; i < res.data.length; i++) { + $("#LotNo").append('<option value =' + res.data[i].LotNo + '>' + res.data[i].LotNo + '</option>'); + } + + form.render('select'); + } else { //涓嶆垚鍔� + layer.msg(res.msg, { + icon: 2, + time: 2000 //2绉掑叧闂紙濡傛灉涓嶉厤缃紝榛樿鏄�3绉掞級 + }, function() {}); + } + }); + </script> </body> </html> diff --git a/Wms/Model/ModelDto/LogDto/TaskDto.cs b/Wms/Model/ModelDto/LogDto/TaskDto.cs index 088aa45..f697f37 100644 --- a/Wms/Model/ModelDto/LogDto/TaskDto.cs +++ b/Wms/Model/ModelDto/LogDto/TaskDto.cs @@ -98,6 +98,11 @@ public string Type { get; set; } /// <summary> + /// Desc:鎵规鍙� + /// </summary> + public string LotNo { get; set; } + + /// <summary> /// Desc:鍙栨秷鏃堕棿 /// Default: /// Nullable:True diff --git a/Wms/WMS.BLL/BllQualityServer/QualityInspectServer.cs b/Wms/WMS.BLL/BllQualityServer/QualityInspectServer.cs index 7fcd8a6..959b073 100644 --- a/Wms/WMS.BLL/BllQualityServer/QualityInspectServer.cs +++ b/Wms/WMS.BLL/BllQualityServer/QualityInspectServer.cs @@ -134,6 +134,23 @@ return isquality; } + /// <summary> + /// 鑾峰彇搴撳瓨鎵规鍙烽泦鍚� + /// </summary> + /// <returns></returns> + /// <exception cref="Exception"></exception> + public List<DataStockDetail> GetLotNoList() + { + try + { + var _list = Db.Queryable<DataStockDetail>().Where(w => w.IsDel == "0" && !string.IsNullOrEmpty(w.LotNo)).ToList(); + return _list; + } + catch (Exception ex) + { + throw new Exception(ex.Message); + } + } #endregion } diff --git a/Wms/WMS.BLL/BllTransServer/RcsServer.cs b/Wms/WMS.BLL/BllTransServer/RcsServer.cs index 6df926f..1e8e7a3 100644 --- a/Wms/WMS.BLL/BllTransServer/RcsServer.cs +++ b/Wms/WMS.BLL/BllTransServer/RcsServer.cs @@ -150,7 +150,7 @@ } noticeNo = soNoticeDetail.Id.ToString(); //鍑哄簱鎬诲崟 - var soNotice = Db.Queryable<BllExportNotice>().Where(w => w.IsDel == "0" && w.SONo == soNoticeDetail.SONo).First(); + /*var soNotice = Db.Queryable<BllExportNotice>().Where(w => w.IsDel == "0" && w.SONo == soNoticeDetail.SONo).First(); if (soNotice == null) { throw new Exception("璇ユ壒娆℃病鏈夊搴旂殑鍑哄簱鍗�"); @@ -158,7 +158,7 @@ soNotice.Status = "3";//姝e湪鎵ц soNotice.UpdateTime = DateTime.Now; //鏇存柊鍑哄簱鍗� - Db.Updateable(soNotice).ExecuteCommand(); + Db.Updateable(soNotice).ExecuteCommand();*/ //鏌ユ壘鍒拌杞﹂棿鍗婃垚鍝佸尯 List<string> areaNoList3 = Db.Queryable<SysStorageArea>().Where(w => w.IsDel == "0" && w.Status == "0" && w.Type == "2" && w.WareHouseNo == houseNo).Select(s => s.AreaNo).ToList(); @@ -259,6 +259,7 @@ Status = "0",//浠诲姟鐘舵��0锛氱瓑寰呮墽琛�1姝e湪鎵ц2鎵ц瀹屾垚 NoticeDetailNo = int.Parse(noticeNo), Msg = taskMsg, //鍏抽敭淇℃伅 + LotNo = item.LotNo//鎵规鍙� }; //缁勭粐涓嬪彂灏忚溅浠诲姟淇℃伅 var task2 = new TaskDetial @@ -332,6 +333,7 @@ Status = "0",//浠诲姟鐘舵��0锛氱瓑寰呮墽琛�1姝e湪鎵ц2鎵ц瀹屾垚 NoticeDetailNo = int.Parse(noticeNo), Msg = taskMsg, //鍏抽敭淇℃伅 + LotNo = pallet.LotNo//鎵规鍙� }; //缁勭粐涓嬪彂灏忚溅浠诲姟淇℃伅 @@ -519,7 +521,7 @@ throw new Exception("鎵规鍙蜂负绌猴紒"); } //鏍¢獙姝ゆ壒娆℃槸鍚︽湁鍏ュ簱鍗� - var noticeDetail = Db.Queryable<BllArrivalNoticeDetail>().Where(w => w.IsDel == "0" && w.Status == "0" && w.LotNo == model.LotNo).OrderByDescending(o => o.CreateTime).First(); + /*var noticeDetail = Db.Queryable<BllArrivalNoticeDetail>().Where(w => w.IsDel == "0" && w.Status == "0" && w.LotNo == model.LotNo).OrderByDescending(o => o.CreateTime).First(); if (noticeDetail == null) { throw new Exception("璇ユ壒娆℃病鏈夊搴旂殑鍏ュ簱鍗曟槑缁�"); @@ -533,7 +535,7 @@ } notice.Status = "1";//姝e湪鎵ц //鏇存柊鍏ュ簱鍗曠姸鎬� - Db.Updateable(notice).ExecuteCommand(); + Db.Updateable(notice).ExecuteCommand();*/ //鏌ユ壘鍒拌杞﹂棿鍗婃垚鍝佸尯 loction = GetLocatModel(houseNo, "2"); @@ -612,6 +614,7 @@ Status = "0",//浠诲姟鐘舵��0锛氱瓑寰呮墽琛�1姝e湪鎵ц2鎵ц瀹屾垚 NoticeDetailNo = int.Parse(noticeno), Msg = taskMsg, //鍏抽敭淇℃伅 + LotNo = palletInfo.LotNo//鎵规鍙� }; var task = new TaskDetial { diff --git a/Wms/WMS.BLL/LogServer/TaskServer.cs b/Wms/WMS.BLL/LogServer/TaskServer.cs index 7a5748a..78074f8 100644 --- a/Wms/WMS.BLL/LogServer/TaskServer.cs +++ b/Wms/WMS.BLL/LogServer/TaskServer.cs @@ -37,8 +37,8 @@ .ToExpression();//娉ㄦ剰 杩欎竴鍙� 涓嶈兘灏� var total = 0; var data = GetAllWhereAsync(item) - .LeftJoin<SysUserInfor>((a,b)=>a.CreateUser == b.Id). - Select((a,b) => new TaskDto() + .LeftJoin<SysUserInfor>((a, b) => a.CreateUser == b.Id). + Select((a, b) => new TaskDto() { Id = a.Id, TaskNo = a.TaskNo, @@ -60,14 +60,16 @@ Type = a.Type, OrderType = a.OrderType, + LotNo = a.LotNo, + CancelDate = a.CancelDate, FinishDate = a.FinishDate, - CreateUserName =b.RealName, + CreateUserName = b.RealName, CreateTime = a.CreateTime }) .OrderByDescending(a => a.TaskNo) - .ToOffsetPage(page,limit,ref total); + .ToOffsetPage(page, limit, ref total); count = total; return data.OrderByDescending(m=>m.TaskNo).ToList(); diff --git a/Wms/WMS.Entity/LogEntity/LogTask.cs b/Wms/WMS.Entity/LogEntity/LogTask.cs index 3ca8f92..7863d61 100644 --- a/Wms/WMS.Entity/LogEntity/LogTask.cs +++ b/Wms/WMS.Entity/LogEntity/LogTask.cs @@ -175,5 +175,11 @@ /// </summary> public string FinishIsPick { get; set; } + /// <summary> + /// Desc:鎵规鍙� + /// Default: + /// Nullable:True + /// </summary> + public string LotNo { get; set; } } } diff --git a/Wms/WMS.IBLL/IBllQualityServer/IQualityInspectServer.cs b/Wms/WMS.IBLL/IBllQualityServer/IQualityInspectServer.cs index 5b3e340..98896f6 100644 --- a/Wms/WMS.IBLL/IBllQualityServer/IQualityInspectServer.cs +++ b/Wms/WMS.IBLL/IBllQualityServer/IQualityInspectServer.cs @@ -4,6 +4,7 @@ using System.Text; using Model.ModelDto.BllQualityDto; using WMS.Entity.BllQualityEntity; +using WMS.Entity.DataEntity; namespace WMS.IBLL.IBllQualityServer { @@ -25,6 +26,11 @@ /// <returns></returns> int InsertQuality(BllQualityInspect model); + /// <summary> + /// 鑾峰彇搴撳瓨鎵规鍙烽泦鍚� + /// </summary> + /// <returns></returns> + public List<DataStockDetail> GetLotNoList(); #endregion } } diff --git a/Wms/Wms/Controllers/BllQualityController.cs b/Wms/Wms/Controllers/BllQualityController.cs index 9f93f4b..258aeec 100644 --- a/Wms/Wms/Controllers/BllQualityController.cs +++ b/Wms/Wms/Controllers/BllQualityController.cs @@ -293,5 +293,25 @@ } } #endregion + + + /// <summary> + /// 鑾峰彇搴撳瓨鎵规鍙烽泦鍚� + /// </summary> + /// <returns></returns> + [HttpGet] + public IActionResult GetLotNoList() + { + try + { + var bolls = _qualityServer.GetLotNoList(); + + return Ok(new { code = 0, msg = "鎵规鍙烽泦鍚�", data = bolls }); + } + catch (Exception e) + { + return Ok(new { code = 1, msg = e.Message }); + } + } } } diff --git a/Wms/Wms/appsettings.json b/Wms/Wms/appsettings.json index 7395bf3..a5363d4 100644 --- a/Wms/Wms/appsettings.json +++ b/Wms/Wms/appsettings.json @@ -17,6 +17,7 @@ //"ConnectionString": "Server=.\\MSSQLSERVER2019;Database=WMS_JC23-2;User Id=sa;Password=admin2023@;" // SqlServer 搴撹繛鎺ュ瓧绗︿覆 //"ConnectionString": "Server=172.16.105.10;Database=WMS_JC23-2;User ID=sa;Password=sql2019;Integrated Security=False;" "ConnectionString": "Server=172.16.105.2;Database=WMS_JC23-2;User ID=sa;Password=boxline@2024;Integrated Security=False;" + //"ConnectionString": "Server=.\\SQLSERVER;Database=WMS_JC23-2;User ID=sa;Password=admin2023@;Integrated Security=False;" }, "JWTConfig": { "Issuer": "WYY", //Token锟斤拷锟斤拷锟斤拷 -- Gitblit v1.8.0