陆晔 2 years ago
parent
commit
054baeadf3
  1. 6
      WMS-BS/NFine.Application/WMS/WMSCreateItemLotApp.cs

6
WMS-BS/NFine.Application/WMS/WMSCreateItemLotApp.cs

@ -960,7 +960,7 @@ where a.Status='2'";
#region [SQL]
string sql = @"select a.ID, '' as 'POCode',-- d.POCode,d.Sequence as POSequence,
'' as POSequence,
a.DNCode,a.Sequence,a.VenCode,e.VenName,a.WHCode,a.InvCode,a.DNID,a.DNDetailID,a.WorkPoint,a.InspectionType,a.InvoDescribe,a.Unity,a.StockIndicator, b.InvName,b.InvStd,b.InvDesc,b.InvUnit, detail.LocationCode AS Area,
a.DNCode,a.Sequence,a.VenCode,a.DepCode AS VenName,a.WHCode,a.InvCode,a.DNID,a.DNDetailID,a.WorkPoint,a.InspectionType,a.InvoDescribe,a.Unity,a.StockIndicator, b.InvName,b.InvStd,b.InvDesc,b.InvUnit, detail.LocationCode AS Area,
CAST(a.Quantity AS DECIMAL(18,{0})) as Quantity ,CAST(a.Amount AS DECIMAL(18,{0})) as Amount,CAST(a.RCVQuantity AS DECIMAL(18,{0})) as RCVQuantity,CAST(a.UnitPrice AS DECIMAL(18,{0})) as UnitPrice,a.Currency,a.CreatePerson,a.CreateDateTime,CAST(c.LOTQTY AS DECIMAL(18,{0})) as LOTQTY
,f.Colspan ,f.ProjectCode ,f.BatchCode ,f.Version ,f.Brand ,f.cFree1 ,f.cFree2 ,f.cFree3 ,f.cFree4
,f.cFree5 ,f.cFree6 ,f.cFree7 ,f.cFree8 ,f.cFree9 ,f.cFree10
@ -994,7 +994,7 @@ where a.DNType='1' and a.Status='2' and a.ASNCode is null
}
if (!string.IsNullOrWhiteSpace(queryParam["VenName"].ToString()))
{
sql += " and e.VenName like '%" + queryParam["VenName"].ToString() + "%' ";
sql += " and a.DepCode like '%" + queryParam["VenName"].ToString() + "%' ";
}
if (!string.IsNullOrWhiteSpace(queryParam["Area"].ToString()))
{
@ -1772,7 +1772,7 @@ where a.DNType='3' and a.Status='2' and a.EATTRIBUTE1 is NOT null
from ICSMOApplyNegDetail a
left join ICSMOApplyNeg d on a.ApplyNegCode=d.ApplyNegCode and a.WorkPoint=d.WorkPoint
left join ICSInventory b on a.InvCode=b.InvCode and a.WorkPoint=b.WorkPoint
LEFT JOIN ICSInventoryDetail detail WHERE b.InvCode=detail.INVCode AND a.WHCode=detail.WHCode AND a.WorkPoint=detail.WorkPoint
LEFT JOIN ICSInventoryDetail detail ON b.InvCode=detail.INVCode AND a.WHCode=detail.WHCode AND a.WorkPoint=detail.WorkPoint
left join (
select mm.TransCode,mm.TransSequence,sum(isnull(ee.Quantity,0)) LOTQTY,ee.WorkPoint from ICSInventoryLot ee
left join ICSInventoryLotDetail mm on ee.LotNo=mm.LotNo and ee.type='12'

Loading…
Cancel
Save