添加基础信息查询的接口
This commit is contained in:
@@ -14,7 +14,7 @@ namespace NX.ERP.U8.Base
|
||||
{
|
||||
using (var conn = new System.Data.SqlClient.SqlConnection(U8LoginContext.Instance.Constr4Net))
|
||||
{
|
||||
var sql = @"select cPosCode as Code,cPosName as Name,iPosGrade,bPosEnd,cWhCode as WhCode,
|
||||
var sql = @"select cPosCode as BinCode,cPosName as BinName,iPosGrade,bPosEnd,cWhCode as WarehouseCode,
|
||||
iMaxCubage as VolumeLimit, iMaxweight as WeightLimit,cMemo,cBarCode from Position";
|
||||
if (!string.IsNullOrEmpty(strwhere))
|
||||
{
|
||||
@@ -30,7 +30,35 @@ namespace NX.ERP.U8.Base
|
||||
{
|
||||
return this.GetList(" cWhCode=@Code", new { Code });
|
||||
}
|
||||
|
||||
|
||||
|
||||
public IEnumerable<Bin> GetList(NX.ERP.Model.Request.Bin Param)
|
||||
{
|
||||
List<string> where = new List<string>();
|
||||
|
||||
if (!string.IsNullOrEmpty(Param.BinCode))
|
||||
{
|
||||
where.Add(" cPosCode like @BinCode");
|
||||
}
|
||||
|
||||
|
||||
if (!string.IsNullOrEmpty(Param.WarehouseCode))
|
||||
{
|
||||
where.Add(" cWhCode like @WarehouseCode");
|
||||
}
|
||||
|
||||
return this.GetList(string.Join(" and ", where.ToArray()), new
|
||||
{
|
||||
BinCode = $"%{Param.BinCode}%",
|
||||
WarehouseCode=$"%{Param.WarehouseCode}%"
|
||||
|
||||
});
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user