外协入库与四楼自动移库逻辑修改、现场问题处理

This commit is contained in:
2024-10-09 18:12:33 +08:00
parent 05714f027d
commit c675ec3e07
16 changed files with 504 additions and 189 deletions

View File

@@ -106,33 +106,33 @@ namespace Tnb.WarehouseMgr
else
{
input.sidx = input.sidx.Replace("create_time", "a.create_time").Replace("erp_bill_code", "e.erp_bill_code");
}
Dictionary<string, object> status_dic = await _db.Queryable<DictionaryTypeEntity>()
.InnerJoin<DictionaryDataEntity>((a, b) => a.Id == b.DictionaryTypeId)
.Where((a, b) => a.FullName == "单据状态").Select((a, b) => b).ToDictionaryAsync(k => k.Id, v => v.FullName);
SqlSugarPagedList<WmsSortingtask> result = await _db.Queryable<WmsSortingtask>()
var _result = await _db.Queryable<WmsSortingtask>()
.InnerJoin<WmsCarryCode>((a, b) => a.carry_id == b.carry_id)
.InnerJoin<BasMaterial>((a, b, c) => b.material_id == c.id)
.InnerJoin<WmsSaleD>((a, b, c, d) => a.source_id == d.id)
.InnerJoin<WmsSaleH>((a, b, c, d, e) => e.id == d.bill_id)
.WhereIF(!string.IsNullOrEmpty(status), (a, b, c, d, e) => a.status == status)
.Select((a, b, c, d, e) => new WmsSortingtask
.InnerJoin<DictionaryDataEntity>((a, b, c, d, e, f) => f.Id == a.status)
.WhereIF(!string.IsNullOrEmpty(status), (a, b, c, d, e, f) => a.status == status)
.Select((a, b, c, d, e, f) => new WmsSortingtask
{
id = a.id,
create_time = DateTime.Parse(a.create_time.ToString("yyyy-MM-dd HH:mm:ss")),
material_id = c.id,
material_code =c.code ,
material_code = c.code,
material_name = c.name,
material_specification =c.material_specification,
material_specification = c.material_specification,
code_batch = b.code_batch,
erp_bill_code = e.erp_bill_code
erp_bill_code = e.erp_bill_code,
status = f.FullName
}, true)
.OrderBy($"{input.sidx} {input.sort}")
.ToPagedListAsync(input.currentPage, input.pageSize);
return PageResult<WmsSortingtask>.SqlSugarPageResult(result);
var result = PageResult<WmsSortingtask>.SqlSugarPageResult(_result);
return result;
}