| | |
| | | height: auto; |
| | | line-height: 23px; |
| | | } |
| | | |
| | | .layui-table-tool-panel{ |
| | | top: auto; |
| | | bottom: 29px; |
| | | } |
| | | |
| | | .layui-table-tool{ |
| | | padding-left: 5px; |
| | | } |
| | | |
| | | /* 表格下拉小箭头隐藏 */ |
| | | .layui-table-grid-down { |
| | | display: none; |
| | |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">入库单号</label> |
| | | <div class="layui-input-inline"> |
| | | <input type="text" id="ASNNo" name="ASNNo" placeholder="入库单号" |
| | | autocomplete="off" class="layui-input"> |
| | | <input type="text" id="ASNNo" name="ASNNo" placeholder="入库单号" autocomplete="off" |
| | | class="layui-input"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label" style="width: 90px;">上游系统单号</label> |
| | | <div class="layui-input-inline"> |
| | | <input type="text" id="OrderCode" name="OrderCode" placeholder="上游系统单号" |
| | | autocomplete="off" class="layui-input"> |
| | | <input type="text" id="OrderCode" name="OrderCode" placeholder="上游系统单号" autocomplete="off" |
| | | class="layui-input"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">客户名称</label> |
| | | <div class="layui-input-inline"> |
| | | <input type="text" id="CustomerName" name="CustomerName" placeholder="客户名称" autocomplete="off" |
| | | class="layui-input"> |
| | | <input type="text" id="CustomerName" name="CustomerName" placeholder="客户名称" |
| | | autocomplete="off" class="layui-input"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | |
| | | <div class="layui-inline" id="divEditDemo" style="display: none; padding-top: 10px;"> |
| | | <label class="layui-form-label">备注</label> |
| | | <div class="layui-input-inline" style="width: 300px;height: 100%;"> |
| | | <textarea placeholder="请输入内容" id="NoticeDemo" name="NoticeDemo" class="layui-textarea"></textarea> |
| | | <textarea placeholder="请输入内容" id="NoticeDemo" name="NoticeDemo" |
| | | class="layui-textarea"></textarea> |
| | | </div> |
| | | </div> |
| | | </div> |
| | |
| | | height: h1, |
| | | id: 'LAY-app-content-list', |
| | | where: param, |
| | | parseData: FnParseData, |
| | | contentType: 'application/json', |
| | | headers:{ToKen:$.cookie('token')}, |
| | | page: true, |
| | |
| | | limits: pageLimits, |
| | | cellMinWidth: 60, //全局定义常规单元格的最小宽度,layui 2.2.1 新增 |
| | | done: function(res) { |
| | | console.log(res); |
| | | setRight(); |
| | | //自定义列宽 |
| | | SetTableColW('LAY-app-content-list','BllAsn/GetArrivalNoticeList',TotalColsSysArr); |
| | |
| | | //#endregion |
| | | } |
| | | |
| | | function setRight() |
| | | { |
| | | function setRight() { |
| | | $(function() { |
| | | $(".addClass").hide(); |
| | | $(".editClass").hide(); |
| | |
| | | var ImportId = 0; |
| | | table.on('tool(LAY-app-content-list)', function (obj) { |
| | | var data = obj.data; |
| | | switch(obj.event) |
| | | { |
| | | switch (obj.event) { |
| | | case "edit" : |
| | | // 代码区域 |
| | | var id = data.ASNNo; |
| | |
| | | table.on('tool(LAY-app-content-list2)', function (obj) { |
| | | var data = obj.data; |
| | | var id = data.Id; |
| | | switch(obj.event) |
| | | { |
| | | switch (obj.event) { |
| | | case "del" : |
| | | layer.confirm('确定删除入库单明细吗?', function(index) { |
| | | // 代码区域 |
| | |
| | | height: h1, |
| | | id: 'LAY-app-content-list', |
| | | where: param, |
| | | parseData: FnParseData, |
| | | contentType: 'application/json', |
| | | headers: { ToKen: $.cookie('token') }, |
| | | page: true, |
| | |
| | | limits: pageLimits, |
| | | cellMinWidth: 60, //全局定义常规单元格的最小宽度,layui 2.2.1 新增 |
| | | done: function (res) { |
| | | console.log(res); |
| | | setRight(); |
| | | //自定义列宽 |
| | | SetTableColW('LAY-app-content-list', 'BllAsn/GetProcurePlanNoticeList', TotalColsSysArr); |
| | |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label" style="width: 56px;">客户编码</label> |
| | | <div class="layui-input-inline"> |
| | | <input type="text" id="CustomerNo" name="CustomerNo" placeholder="客户编码" |
| | | autocomplete="off" class="layui-input" |
| | | onkeyup="this.value=this.value.replace(/[, ]/g,'')"> |
| | | <input type="text" id="CustomerNo" name="CustomerNo" placeholder="客户编码" autocomplete="off" |
| | | class="layui-input" onkeyup="this.value=this.value.replace(/[, ]/g,'')"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | |
| | | // response:{ |
| | | // statusCode: 0 |
| | | // }, |
| | | done: function () { |
| | | done: function (ref) { |
| | | console.log(ref); |
| | | $(function() { |
| | | $(".editClass").hide(); |
| | | $(".delClass").hide(); |
| | |
| | | using System; |
| | | using System.Collections.Generic; |
| | | using System.Text; |
| | | using System.Threading.Tasks; |
| | | using WMS.BLL.LogServer; |
| | | using WMS.DAL; |
| | | using WMS.Entity.BllAsnEntity; |
| | |
| | | /// <param name="model"></param> |
| | | /// <param name="count"></param> |
| | | /// <returns></returns> |
| | | public List<ProcurePlanNoticeDto> GetProcurePlanNoticeList(ProcurePlanNoticeVm model, out int count) |
| | | public async Task<List<ProcurePlanNoticeDto>> GetProcurePlanNoticeList(ProcurePlanNoticeVm model, RefAsync<int> count) |
| | | { |
| | | string sqlString = string.Empty; |
| | | string sqlCount = string.Empty; |
| | | string sqlPub = string.Empty; |
| | | try |
| | | { |
| | | sqlCount += "SELECT DISTINCT COUNT(tb1.ID) FROM BllProcurePlanNotice AS tb1 "; |
| | | sqlString += "SELECT DISTINCT tb1.*,tb3.RealName as CreateUserName,tb4.RealName as UpdateUserName FROM BllProcurePlanNotice AS tb1 "; |
| | | sqlPub += "LEFT JOIN BllProcurePlanNoticeDetail AS tb2 ON tb1.Id = tb2.ParentId "; |
| | | sqlPub += "LEFT JOIN SysUserInfor AS tb3 ON tb1.CreateUser = tb3.Id "; |
| | | sqlPub += "LEFT JOIN SysUserInfor AS tb4 ON tb1.UpdateUser = tb4.Id "; |
| | | sqlPub += $"WHERE tb1.IsDel = '0' "; |
| | | sqlPub += $"AND tb2.SkuNo LIKE '%{model.SkuNo}%' AND tb2.SkuName LIKE '%{model.SkuName}%' "; |
| | | sqlPub += $"AND tb2.CustomerName LIKE '%{model.CustomerName}%' "; |
| | | if (!string.IsNullOrEmpty(model.Status)) |
| | | { |
| | | sqlPub += $"AND tb1.Status = '{model.Status}' "; |
| | | } |
| | | if (!string.IsNullOrEmpty(model.StartTime)) |
| | | { |
| | | sqlPub += $"AND tb1.CreateTime >= '{model.StartTime}' "; |
| | | } |
| | | if (!string.IsNullOrEmpty(model.EndTime)) |
| | | { |
| | | sqlPub += $"AND tb1.CreateTime <= '{model.EndTime}' "; |
| | | } |
| | | sqlCount += sqlPub; |
| | | sqlPub += " order by tb1.Id desc "; |
| | | if (model.Page == 0) |
| | | { |
| | | model.Page = 1; |
| | | } |
| | | sqlString += sqlPub + $" offset {((model.Page - 1) * model.Limit)} rows fetch next {model.Limit} rows only;"; |
| | | |
| | | var com = new Common(); |
| | | count = com.GetRowCount(sqlCount); |
| | | |
| | | var modelList = Db.Ado.SqlQuery<ProcurePlanNoticeDto>(sqlString); |
| | | var modelList = await Db.Queryable<BllProcurePlanNotice>() |
| | | .LeftJoin<BllProcurePlanNoticeDetail>((tb1, tb2) => tb1.Id == tb2.ParentId) |
| | | .LeftJoin<SysUserInfor>((tb1, tb2, tb3) => tb1.CreateUser == tb3.Id) |
| | | .LeftJoin<SysUserInfor>((tb1, tb2, tb3, tb4) => tb1.UpdateUser == tb4.Id) |
| | | .WhereIF(!string.IsNullOrWhiteSpace(model.Status), tb1 => tb1.Status == model.Status) |
| | | .WhereIF(!string.IsNullOrWhiteSpace(model.StartTime), tb1 => tb1.CreateTime >= Convert.ToDateTime(model.StartTime)) |
| | | .WhereIF(!string.IsNullOrWhiteSpace(model.EndTime), tb1 => tb1.CreateTime <= Convert.ToDateTime(model.EndTime).AddDays(1)) |
| | | .WhereIF(!string.IsNullOrWhiteSpace(model.SkuName), (tb1,tb2) => tb2.SkuName.Contains(model.SkuName)) |
| | | .Where(tb1 => tb1.IsDel == "0") |
| | | .OrderByDescending(tb1 => tb1.Id) |
| | | .Distinct() |
| | | .Select((tb1, tb2, tb3, tb4) => new ProcurePlanNoticeDto() { |
| | | Id = tb1.Id, |
| | | Status = tb1.Status, |
| | | OrderCode = tb1.OrderCode, |
| | | UserName = tb1.UserName, |
| | | CompleteTime = tb1.CompleteTime, |
| | | CreateTime = tb1.CreateTime, |
| | | CreateUserName = tb3.RealName, |
| | | UpdateTime = tb1.UpdateTime.ToString(), |
| | | UpdateUserName = tb4.RealName |
| | | }).ToPageListAsync(model.Page, model.Limit, count); |
| | | |
| | | return modelList; |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | throw ex; |
| | | } |
| | | } |
| | | /// <summary> |
| | | /// 获取采购单明细信息 |
| | |
| | | public DateTime? CompleteTime { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 制单人 |
| | | /// </summary> |
| | | public string UserName { get; set; } |
| | | |
| | | /// <summary> |
| | | /// 上游系统单号 |
| | | /// </summary> |
| | | public string OrderCode { get; set; } |
| | |
| | | using Model.InterFaceModel; |
| | | using Model.ModelDto.BllAsnDto; |
| | | using Model.ModelVm.BllAsnVm; |
| | | using SqlSugar; |
| | | using System; |
| | | using System.Collections.Generic; |
| | | using System.Text; |
| | | using System.Threading.Tasks; |
| | | |
| | | namespace WMS.IBLL.IBllAsnServer |
| | | { |
| | |
| | | /// <param name="model"></param> |
| | | /// <param name="count"></param> |
| | | /// <returns></returns> |
| | | public List<ProcurePlanNoticeDto> GetProcurePlanNoticeList(ProcurePlanNoticeVm model, out int count); |
| | | Task <List<ProcurePlanNoticeDto>> GetProcurePlanNoticeList(ProcurePlanNoticeVm model, RefAsync<int> count); |
| | | |
| | | /// <summary> |
| | | /// 获取采购单明细信息 |
| | |
| | | using WMS.IBLL.IBllAsnServer; |
| | | using WMS.IBLL.ILogServer; |
| | | using Model.ModelVm.BllAsnVm; |
| | | using Utility; |
| | | using Model.ModelDto.BllAsnDto; |
| | | using System.Threading.Tasks; |
| | | using SqlSugar; |
| | | |
| | | namespace Wms.Controllers |
| | | { |
| | | [Route("api/[controller]/[action]")] |
| | | [ApiController] |
| | | [Authorize] |
| | | |
| | | public class BllAsnController : ControllerBase |
| | | { |
| | | #region 依赖注入 |
| | |
| | | /// 获取采购单信息 |
| | | /// </summary> |
| | | /// <param name="model">查询条件</param> |
| | | /// <returns>入库单信息</returns> |
| | | /// <returns>采购单信息</returns> |
| | | [HttpPost] |
| | | public IActionResult GetProcurePlanNoticeList(ProcurePlanNoticeVm model) |
| | | [ServiceFilter(typeof(ApiResponseActionFilter))] |
| | | public async Task<SqlSugarPagedList<ProcurePlanNoticeDto>> GetProcurePlanNoticeList(ProcurePlanNoticeVm model) |
| | | { |
| | | try |
| | | { |
| | | var models = _procurePlanSvc.GetProcurePlanNoticeList(model, out int count); |
| | | |
| | | return Ok(new { code = 0, count, msg = "入库单信息", data = models }); |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | return Ok(new { code = 1, msg = e.Message }); |
| | | } |
| | | RefAsync<int> count = new RefAsync<int>(); |
| | | var bolls = await _procurePlanSvc.GetProcurePlanNoticeList(model, count); |
| | | return new SqlSugarPagedList<ProcurePlanNoticeDto>() { Items = bolls, Total = count }; |
| | | } |
| | | /// <summary> |
| | | /// 获取采购单明细信息 |