|
@ -167,12 +167,44 @@ where b.MOCode='{0}' and a.WorkPoint='{1}'"; |
|
|
{ |
|
|
{ |
|
|
sqlString.Append($@" and a.NeedDate like '%{queryParam["NeedDate"]}%' "); |
|
|
sqlString.Append($@" and a.NeedDate like '%{queryParam["NeedDate"]}%' "); |
|
|
} |
|
|
} |
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(queryParam["Status"].ToString())) |
|
|
|
|
|
{ |
|
|
|
|
|
if (queryParam["NeedDate"].ToString() == "3") |
|
|
|
|
|
{ |
|
|
|
|
|
sqlString.Append($@" and sum(a.Quantity) = sum(IssueQuantity) and a.MUSERName != 'JOB "); |
|
|
|
|
|
} |
|
|
|
|
|
else if (queryParam["NeedDate"].ToString() == "2") |
|
|
|
|
|
{ |
|
|
|
|
|
sqlString.Append($@" and sum(a.Quantity) =sum(IssueQuantity) and a.MUSERName = 'JOB' "); |
|
|
|
|
|
} |
|
|
|
|
|
else if(queryParam["NeedDate"].ToString() == "1") |
|
|
|
|
|
{ |
|
|
|
|
|
sqlString.Append($@" and sum(a.Quantity) >= sum(IssueQuantity) "); |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
sqlString.Append(@" group by a.ApplyCode, a.WorkPoint,a.IssueQuantity,a.CreateDateTime,a.createperson,
|
|
|
sqlString.Append(@" group by a.ApplyCode, a.WorkPoint,a.IssueQuantity,a.CreateDateTime,a.createperson,
|
|
|
f.Colspan,f.ProjectCode,f.BatchCode,f.Version,f.Brand,f.cFree1,f.cFree2, |
|
|
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,a.WHCode,detail.LocationCode,a.ID,a.EATTRIBUTE,a.Sets,a.OrderInvCode,a.OrderInvDescribe,a.BillType,a.Remarks,a.Desks,a.DispatchNumber,a.DispatcherName, |
|
|
f.cFree3,f.cFree4,f.cFree5,f.cFree6,f.cFree7,f.cFree8,f.cFree9,f.cFree10,a.WHCode,detail.LocationCode,a.ID,a.EATTRIBUTE,a.Sets,a.OrderInvCode,a.OrderInvDescribe,a.BillType,a.Remarks,a.Desks,a.DispatchNumber,a.DispatcherName, |
|
|
a.ReceiverNumber,a.ReceiverName,a.Urgency,a.NeedDate,a.NeedTime,a.RemarksTerm,a.TextNumber,a.InvDescribe,a.Unit,a.StockIndicator,a.MUSERName) as t where t.row=1");
|
|
|
a.ReceiverNumber,a.ReceiverName,a.Urgency,a.NeedDate,a.NeedTime,a.RemarksTerm,a.TextNumber,a.InvDescribe,a.Unit,a.StockIndicator,a.MUSERName) as t where t.row=1");
|
|
|
|
|
|
|
|
|
|
|
|
if (!string.IsNullOrWhiteSpace(queryParam["Status"].ToString())) |
|
|
|
|
|
{ |
|
|
|
|
|
if (queryParam["Status"].ToString() == "3") |
|
|
|
|
|
{ |
|
|
|
|
|
sqlString.Append($@" AND t.Status='已过帐' "); |
|
|
|
|
|
} |
|
|
|
|
|
else if (queryParam["Status"].ToString() == "2") |
|
|
|
|
|
{ |
|
|
|
|
|
sqlString.Append($@" AND t.Status='已配料' "); |
|
|
|
|
|
} |
|
|
|
|
|
else if (queryParam["Status"].ToString() == "1") |
|
|
|
|
|
{ |
|
|
|
|
|
sqlString.Append($@" AND t.Status='未配料' "); |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
#endregion
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -2574,7 +2606,7 @@ b.InvUnit, |
|
|
} |
|
|
} |
|
|
else if (dts2 != null && dts2.Rows.Count > 0) |
|
|
else if (dts2 != null && dts2.Rows.Count > 0) |
|
|
{ |
|
|
{ |
|
|
msg = "当前选择单据号存在已出库的单据号,合并拣料失败"; |
|
|
|
|
|
|
|
|
msg = "当前选择单据号存在已出库的单据号,合并 失败"; |
|
|
} |
|
|
} |
|
|
else |
|
|
else |
|
|
{ |
|
|
{ |
|
|