|
|
@ -424,6 +424,7 @@ namespace CK.SCP.Controller |
|
|
|
DataSet _ds = new DataSet(); |
|
|
|
using (ScpEntities db = EntitiesFactory.CreateScpInstance()) |
|
|
|
{ |
|
|
|
db.Database.CommandTimeout = 300; |
|
|
|
List<V_TB_ARRIVE> _ls = new List<V_TB_ARRIVE>(); |
|
|
|
if (!string.IsNullOrEmpty(p_vendid)) |
|
|
|
{ |
|
|
@ -446,7 +447,6 @@ namespace CK.SCP.Controller |
|
|
|
{ |
|
|
|
_ls = db.V_TB_ARRIVE.Where(p => p_lst.Contains(p.ArrvBillNum)).ToList(); |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
var str = JsonHelper.GetJson(_ls); |
|
|
@ -497,7 +497,6 @@ namespace CK.SCP.Controller |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
_detailList.ForEach(itm => { |
|
|
|
var _entity = new SCP_ARRIVE_DETAIL_EXPORT(); |
|
|
|
_entity.单据号 = itm.ArrvBillNum; |
|
|
@ -505,8 +504,12 @@ namespace CK.SCP.Controller |
|
|
|
_entity.订单号 = itm.PoBillNum; |
|
|
|
_entity.订单行 = itm.PoLine.ToString(); |
|
|
|
_entity.零件号 = itm.PartCode; |
|
|
|
_entity.零件名称 = itm.PartDesc1; |
|
|
|
_entity.单位 = itm.Unit; |
|
|
|
var partModel = db.TA_PART.FirstOrDefault(p => p.PartCode == itm.PartCode && p.Site == itm.Site); |
|
|
|
if (partModel != null) |
|
|
|
{ |
|
|
|
_entity.零件名称 = partModel.PartDesc1; |
|
|
|
_entity.单位 = partModel.Unit; |
|
|
|
} |
|
|
|
_entity.数量 = itm.Qty.ToString(); |
|
|
|
_entity.时间 = itm.ShipTime == null ? string.Empty : itm.ShipTime.Value.ToString("yyyyMMdd"); |
|
|
|
_entity.备注 = itm.Remark; |
|
|
|