This commit is contained in:
liangjunyu
2025-10-31 09:13:33 +08:00
parent f3240a3028
commit 51f63090e6

View File

@@ -11361,33 +11361,6 @@ namespace RB_MES_API.Controllers
};
}).ToList();
////添加单据体,按订单号找到它的明细数据
//List<STK_TransferDirect.BillEntry> entries = (from a in head
// join b in R011cs on a.TRX_DATE equals b.TRX_DATE
// join c in marylist on b.MTRL_ID equals c.FNumber
// join d in units on c.FStoreUnitID equals d.FUNITID
// join e in units on c.FBaseUnitId equals e.FUNITID
// select new STK_TransferDirect.BillEntry
// {
// FMaterialId = new Dictionary<string, string>() { { "FNumber", b.MTRL_ID } },
// FNoteEntry = b.REMARK,
// FLot = new Dictionary<string, string>() { { "FNumber", b.ERP_LOTNO } },
// FDestLot = new Dictionary<string, string>() { { "FNumber", b.ERP_LOTNO } },
// FQty = decimal.Parse(b.QUANTITY),
// FDestStockId = new Dictionary<string, string>() { { "FNumber", b.TOSTORE_ID } },
// FUnitID = new Dictionary<string, string>() { { "FNumber", c.FUnitNumber } },
// FBaseUnitId = new Dictionary<string, string>() { { "FNumber", c.FBaseUnitNumber } },
// FSrcStockId = new Dictionary<string, string>() { { "FNumber", b.STORE_ID } },
// FSaleQty = decimal.Parse(b.QUANTITY),
// FSaleUnitId = new Dictionary<string, string>() { { "FNumber", c.FUnitNumber } },
// FActQty = decimal.Parse(b.QUANTITY),
// FSalBaseQty = Math.Round(decimal.Parse(b.QUANTITY) / (d.FConvertNumerator / d.FConvertDenominator), d.FPrecision),
// FBaseQty = Math.Round(decimal.Parse(b.QUANTITY) / (d.FConvertNumerator / d.FConvertDenominator), d.FPrecision),
// FOwnerOutId = new Dictionary<string, string>() { { "FNumber", LocalStaticRequest.DefaultOrg } },
// FAuxPropId = string.IsNullOrEmpty(b.MTRL_VER) ? null : new STK_TransferDirect.BillEntry.AuxpropId() { FAUXPROPID__FF100001 = new Dictionary<string, string>() { { "FNumber", b.MTRL_VER } } }
// }
// ).Distinct().ToList()
// ;
var q = entries.Where(s => s.FQty <= 0).ToList();
if (q.Count > 0)
{